public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc(refs/users/marxin/heads/backport-9-v6)] gcov: fix streaming of HIST_TYPE_IOR histogram type.
@ 2020-10-02 8:17 Martin Liska
0 siblings, 0 replies; 3+ messages in thread
From: Martin Liska @ 2020-10-02 8:17 UTC (permalink / raw)
To: gcc-cvs
https://gcc.gnu.org/g:f070a482cf7b51716a9933302be246831ef0c236
commit f070a482cf7b51716a9933302be246831ef0c236
Author: Martin Liska <mliska@suse.cz>
Date: Thu Oct 1 21:28:30 2020 +0200
gcov: fix streaming of HIST_TYPE_IOR histogram type.
gcc/ChangeLog:
PR gcov-profile/64636
* value-prof.c (stream_out_histogram_value): Allow negative
values for HIST_TYPE_IOR.
(cherry picked from commit 1921ebcaf6467996aede69e1bbe32400d8a20fe7)
Diff:
---
gcc/value-prof.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/gcc/value-prof.c b/gcc/value-prof.c
index 5013956cf86..b8ce4bd82ce 100644
--- a/gcc/value-prof.c
+++ b/gcc/value-prof.c
@@ -363,7 +363,10 @@ stream_out_histogram_value (struct output_block *ob, histogram_value hist)
/* When user uses an unsigned type with a big value, constant converted
to gcov_type (a signed type) can be negative. */
gcov_type value = hist->hvalue.counters[i];
- if (hist->type == HIST_TYPE_SINGLE_VALUE && i == 0)
+ if ((hist->type == HIST_TYPE_SINGLE_VALUE && i == 0)
+ || hist->type == HIST_TYPE_IOR)
+ /* Note that the IOR counter tracks pointer values and these can have
+ sign bit set. */
;
else
gcc_assert (value >= 0);
^ permalink raw reply [flat|nested] 3+ messages in thread
* [gcc(refs/users/marxin/heads/backport-9-v6)] gcov: fix streaming of HIST_TYPE_IOR histogram type.
@ 2020-10-01 19:40 Martin Liska
0 siblings, 0 replies; 3+ messages in thread
From: Martin Liska @ 2020-10-01 19:40 UTC (permalink / raw)
To: gcc-cvs
https://gcc.gnu.org/g:bfef905ab0c9e7d28b9dc8582fc53a18f518a14f
commit bfef905ab0c9e7d28b9dc8582fc53a18f518a14f
Author: Martin Liska <mliska@suse.cz>
Date: Thu Oct 1 21:28:30 2020 +0200
gcov: fix streaming of HIST_TYPE_IOR histogram type.
gcc/ChangeLog:
PR gcov-profile/64636
* value-prof.c (stream_out_histogram_value): Allow negative
values for HIST_TYPE_IOR.
(cherry picked from commit 1921ebcaf6467996aede69e1bbe32400d8a20fe7)
Diff:
---
gcc/value-prof.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/gcc/value-prof.c b/gcc/value-prof.c
index 5013956cf86..b8ce4bd82ce 100644
--- a/gcc/value-prof.c
+++ b/gcc/value-prof.c
@@ -363,7 +363,10 @@ stream_out_histogram_value (struct output_block *ob, histogram_value hist)
/* When user uses an unsigned type with a big value, constant converted
to gcov_type (a signed type) can be negative. */
gcov_type value = hist->hvalue.counters[i];
- if (hist->type == HIST_TYPE_SINGLE_VALUE && i == 0)
+ if ((hist->type == HIST_TYPE_SINGLE_VALUE && i == 0)
+ || hist->type == HIST_TYPE_IOR)
+ /* Note that the IOR counter tracks pointer values and these can have
+ sign bit set. */
;
else
gcc_assert (value >= 0);
^ permalink raw reply [flat|nested] 3+ messages in thread
* [gcc(refs/users/marxin/heads/backport-9-v6)] gcov: fix streaming of HIST_TYPE_IOR histogram type.
@ 2020-10-01 19:29 Martin Liska
0 siblings, 0 replies; 3+ messages in thread
From: Martin Liska @ 2020-10-01 19:29 UTC (permalink / raw)
To: gcc-cvs
https://gcc.gnu.org/g:691c4ac3088ce4a1553f7ab62856b3cd3a1ab465
commit 691c4ac3088ce4a1553f7ab62856b3cd3a1ab465
Author: Martin Liska <mliska@suse.cz>
Date: Thu Oct 1 21:28:30 2020 +0200
gcov: fix streaming of HIST_TYPE_IOR histogram type.
gcc/ChangeLog:
PR gcov-profile/64636
* value-prof.c (stream_out_histogram_value): Allow negative
values for HIST_TYPE_IOR.
(cherry picked from commit 1921ebcaf6467996aede69e1bbe32400d8a20fe7)
Diff:
---
gcc/value-prof.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/gcc/value-prof.c b/gcc/value-prof.c
index 5013956cf86..b8ce4bd82ce 100644
--- a/gcc/value-prof.c
+++ b/gcc/value-prof.c
@@ -363,7 +363,10 @@ stream_out_histogram_value (struct output_block *ob, histogram_value hist)
/* When user uses an unsigned type with a big value, constant converted
to gcov_type (a signed type) can be negative. */
gcov_type value = hist->hvalue.counters[i];
- if (hist->type == HIST_TYPE_SINGLE_VALUE && i == 0)
+ if ((hist->type == HIST_TYPE_SINGLE_VALUE && i == 0)
+ || hist->type == HIST_TYPE_IOR)
+ /* Note that the IOR counter tracks pointer values and these can have
+ sign bit set. */
;
else
gcc_assert (value >= 0);
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-10-02 8:17 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-10-02 8:17 [gcc(refs/users/marxin/heads/backport-9-v6)] gcov: fix streaming of HIST_TYPE_IOR histogram type Martin Liska
-- strict thread matches above, loose matches on Subject: below --
2020-10-01 19:40 Martin Liska
2020-10-01 19:29 Martin Liska
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).