You can subscribe to this list here.
| 2002 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
(122) |
Nov
(152) |
Dec
(69) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2003 |
Jan
(6) |
Feb
(25) |
Mar
(73) |
Apr
(82) |
May
(24) |
Jun
(25) |
Jul
(10) |
Aug
(11) |
Sep
(10) |
Oct
(54) |
Nov
(203) |
Dec
(182) |
| 2004 |
Jan
(307) |
Feb
(305) |
Mar
(430) |
Apr
(312) |
May
(187) |
Jun
(342) |
Jul
(487) |
Aug
(637) |
Sep
(336) |
Oct
(373) |
Nov
(441) |
Dec
(210) |
| 2005 |
Jan
(385) |
Feb
(480) |
Mar
(636) |
Apr
(544) |
May
(679) |
Jun
(625) |
Jul
(810) |
Aug
(838) |
Sep
(634) |
Oct
(521) |
Nov
(965) |
Dec
(543) |
| 2006 |
Jan
(494) |
Feb
(431) |
Mar
(546) |
Apr
(411) |
May
(406) |
Jun
(322) |
Jul
(256) |
Aug
(401) |
Sep
(345) |
Oct
(542) |
Nov
(308) |
Dec
(481) |
| 2007 |
Jan
(427) |
Feb
(326) |
Mar
(367) |
Apr
(255) |
May
(244) |
Jun
(204) |
Jul
(223) |
Aug
(231) |
Sep
(354) |
Oct
(374) |
Nov
(497) |
Dec
(362) |
| 2008 |
Jan
(322) |
Feb
(482) |
Mar
(658) |
Apr
(422) |
May
(476) |
Jun
(396) |
Jul
(455) |
Aug
(267) |
Sep
(280) |
Oct
(253) |
Nov
(232) |
Dec
(304) |
| 2009 |
Jan
(486) |
Feb
(470) |
Mar
(458) |
Apr
(423) |
May
(696) |
Jun
(461) |
Jul
(551) |
Aug
(575) |
Sep
(134) |
Oct
(110) |
Nov
(157) |
Dec
(102) |
| 2010 |
Jan
(226) |
Feb
(86) |
Mar
(147) |
Apr
(117) |
May
(107) |
Jun
(203) |
Jul
(193) |
Aug
(238) |
Sep
(300) |
Oct
(246) |
Nov
(23) |
Dec
(75) |
| 2011 |
Jan
(133) |
Feb
(195) |
Mar
(315) |
Apr
(200) |
May
(267) |
Jun
(293) |
Jul
(353) |
Aug
(237) |
Sep
(278) |
Oct
(611) |
Nov
(274) |
Dec
(260) |
| 2012 |
Jan
(303) |
Feb
(391) |
Mar
(417) |
Apr
(441) |
May
(488) |
Jun
(655) |
Jul
(590) |
Aug
(610) |
Sep
(526) |
Oct
(478) |
Nov
(359) |
Dec
(372) |
| 2013 |
Jan
(467) |
Feb
(226) |
Mar
(391) |
Apr
(281) |
May
(299) |
Jun
(252) |
Jul
(311) |
Aug
(352) |
Sep
(481) |
Oct
(571) |
Nov
(222) |
Dec
(231) |
| 2014 |
Jan
(185) |
Feb
(329) |
Mar
(245) |
Apr
(238) |
May
(281) |
Jun
(399) |
Jul
(382) |
Aug
(500) |
Sep
(579) |
Oct
(435) |
Nov
(487) |
Dec
(256) |
| 2015 |
Jan
(338) |
Feb
(357) |
Mar
(330) |
Apr
(294) |
May
(191) |
Jun
(108) |
Jul
(142) |
Aug
(261) |
Sep
(190) |
Oct
(54) |
Nov
(83) |
Dec
(22) |
| 2016 |
Jan
(49) |
Feb
(89) |
Mar
(33) |
Apr
(50) |
May
(27) |
Jun
(34) |
Jul
(53) |
Aug
(53) |
Sep
(98) |
Oct
(206) |
Nov
(93) |
Dec
(53) |
| 2017 |
Jan
(65) |
Feb
(82) |
Mar
(102) |
Apr
(86) |
May
(187) |
Jun
(67) |
Jul
(23) |
Aug
(93) |
Sep
(65) |
Oct
(45) |
Nov
(35) |
Dec
(17) |
| 2018 |
Jan
(26) |
Feb
(35) |
Mar
(38) |
Apr
(32) |
May
(8) |
Jun
(43) |
Jul
(27) |
Aug
(30) |
Sep
(43) |
Oct
(42) |
Nov
(38) |
Dec
(67) |
| 2019 |
Jan
(32) |
Feb
(37) |
Mar
(53) |
Apr
(64) |
May
(49) |
Jun
(18) |
Jul
(14) |
Aug
(53) |
Sep
(25) |
Oct
(30) |
Nov
(49) |
Dec
(31) |
| 2020 |
Jan
(87) |
Feb
(45) |
Mar
(37) |
Apr
(51) |
May
(99) |
Jun
(36) |
Jul
(11) |
Aug
(14) |
Sep
(20) |
Oct
(24) |
Nov
(40) |
Dec
(23) |
| 2021 |
Jan
(14) |
Feb
(53) |
Mar
(85) |
Apr
(15) |
May
(19) |
Jun
(3) |
Jul
(14) |
Aug
(1) |
Sep
(57) |
Oct
(73) |
Nov
(56) |
Dec
(22) |
| 2022 |
Jan
(3) |
Feb
(22) |
Mar
(6) |
Apr
(55) |
May
(46) |
Jun
(39) |
Jul
(15) |
Aug
(9) |
Sep
(11) |
Oct
(34) |
Nov
(20) |
Dec
(36) |
| 2023 |
Jan
(79) |
Feb
(41) |
Mar
(99) |
Apr
(169) |
May
(48) |
Jun
(16) |
Jul
(16) |
Aug
(57) |
Sep
(19) |
Oct
|
Nov
|
Dec
|
| S | M | T | W | T | F | S |
|---|---|---|---|---|---|---|
|
|
|
|
1
(4) |
2
(3) |
3
|
4
(1) |
|
5
|
6
|
7
|
8
(1) |
9
|
10
|
11
|
|
12
|
13
(2) |
14
|
15
|
16
|
17
(3) |
18
|
|
19
|
20
(4) |
21
(4) |
22
|
23
(4) |
24
|
25
|
|
26
|
27
(1) |
28
|
29
(6) |
30
(1) |
|
|
|
From: Josef W. <Jos...@gm...> - 2016-06-20 21:39:19
|
Am 20.06.2016 um 22:26 schrieb Christian Borntraeger: > Simple testcase with 2 branches, both are detected: > > # cat test.s > .globl _start > _start: > brasl 14,test # save next address into r14, call test > svc 1 # exit system call > > test: > br 14 # jump to r14 What is the VEX IR both with/without chase value set to 0 for this nice small example? I would be interested to see the IR before and after instrumentation, ie. "--trace-flags=01100000". Josef > # gcc -nostdlib test.s > # valgrind --tool=cachegrind --branch-sim=yes --cache-sim=no ./a.out > ==72006== Cachegrind, a cache and branch-prediction profiler > ==72006== Copyright (C) 2002-2015, and GNU GPL'd, by Nicholas Nethercote et al. > ==72006== Using Valgrind-3.11.0 and LibVEX; rerun with -h for copyright info > ==72006== Command: ./a.out > ==72006== > --72006-- warning: L4 cache found, using its data for the LL simulation. > ==72006== > ==72006== I refs: 3 > ==72006== > ==72006== Branches: 2 (1 cond + 1 ind) > ==72006== Mispredicts: 0 (0 cond + 0 ind) > ==72006== Mispred rate: 0.0% (0.0% + 0.0% ) > > > >> Josef >> >> >> PS: on real hardware, the branch prediction probably would get active here, as >> we may want to predict the control flow change before we even can decode >> the "brasl"... but such behavior never was implemented in the branch simulation >> in cachegrind. >> > > |
|
From: Christian B. <bor...@de...> - 2016-06-20 20:26:57
|
On 06/20/2016 10:14 PM, Josef Weidendorfer wrote: > Am 20.06.2016 um 21:41 schrieb Christian Borntraeger: >> On 06/17/2016 04:02 PM, Josef Weidendorfer wrote: >>> >>> For such a lost branch, can you check if this is a conditional or indirect >>> branch? I wonder why the branch predictor is not called if chasing is done. >>> >> >> Its about unconditional direct branches (calls) >> e.g. >> >> >> ==== SB 37 (evchecks 68) [tid 1] 0x4004e92 _dl_start+1274 /usr/lib64/ld-2.22.so+0x4e92 >> >> ... > >> brasl %r14,.+29460 >> ------ IMark(0x4004E9C, 6, 0) ------ >> PUT(304) = 0x4004EA2:I64 >> PUT(336) = 0x400C1B0:I64 >> >> >> <--- This branch becomes a nop IR-wise due to resteering. > > > > I still do not understand. > If chasing is switched off, this would become the end of an IRSB. > > But this still does not result in the branch simulator to be invoked: > in cachegrind/cg_main.c, addEvent_Bc is only called with Ist_Exit statements, > and addEvent_Bi only with unknown targets. Both is not the case here. > > So it should not matter for branch simulation for this branch to become a nop? > If you get different results with/without chasing here, something must be wrong... Yes, I do see differences in the numbers when changing the the chase value to 0. The differences are not that big, so indeed it might be a bug somewhere else, but it seems that the branch prediction (do_ind_branch_predict) __IS__ called for the brasl calls. It just does not decide about mispredict/predict, but the calls are at least counted, it seems. Simple testcase with 2 branches, both are detected: # cat test.s .globl _start _start: brasl 14,test # save next address into r14, call test svc 1 # exit system call test: br 14 # jump to r14 # gcc -nostdlib test.s # valgrind --tool=cachegrind --branch-sim=yes --cache-sim=no ./a.out ==72006== Cachegrind, a cache and branch-prediction profiler ==72006== Copyright (C) 2002-2015, and GNU GPL'd, by Nicholas Nethercote et al. ==72006== Using Valgrind-3.11.0 and LibVEX; rerun with -h for copyright info ==72006== Command: ./a.out ==72006== --72006-- warning: L4 cache found, using its data for the LL simulation. ==72006== ==72006== I refs: 3 ==72006== ==72006== Branches: 2 (1 cond + 1 ind) ==72006== Mispredicts: 0 (0 cond + 0 ind) ==72006== Mispred rate: 0.0% (0.0% + 0.0% ) > Josef > > > PS: on real hardware, the branch prediction probably would get active here, as > we may want to predict the control flow change before we even can decode > the "brasl"... but such behavior never was implemented in the branch simulation > in cachegrind. > |
|
From: Josef W. <Jos...@gm...> - 2016-06-20 20:14:35
|
Am 20.06.2016 um 21:41 schrieb Christian Borntraeger: > On 06/17/2016 04:02 PM, Josef Weidendorfer wrote: >> >> For such a lost branch, can you check if this is a conditional or indirect >> branch? I wonder why the branch predictor is not called if chasing is done. >> > > Its about unconditional direct branches (calls) > e.g. > > > ==== SB 37 (evchecks 68) [tid 1] 0x4004e92 _dl_start+1274 /usr/lib64/ld-2.22.so+0x4e92 > > ... > brasl %r14,.+29460 > ------ IMark(0x4004E9C, 6, 0) ------ > PUT(304) = 0x4004EA2:I64 > PUT(336) = 0x400C1B0:I64 > > > <--- This branch becomes a nop IR-wise due to resteering. I still do not understand. If chasing is switched off, this would become the end of an IRSB. But this still does not result in the branch simulator to be invoked: in cachegrind/cg_main.c, addEvent_Bc is only called with Ist_Exit statements, and addEvent_Bi only with unknown targets. Both is not the case here. So it should not matter for branch simulation for this branch to become a nop? If you get different results with/without chasing here, something must be wrong... Josef PS: on real hardware, the branch prediction probably would get active here, as we may want to predict the control flow change before we even can decode the "brasl"... but such behavior never was implemented in the branch simulation in cachegrind. |
|
From: Christian B. <bor...@de...> - 2016-06-20 19:42:01
|
On 06/17/2016 04:02 PM, Josef Weidendorfer wrote:
> Am 17.06.2016 um 15:22 schrieb Christian Borntraeger:
>> On 06/17/2016 03:01 PM, Josef Weidendorfer wrote:
>>> Chasing of BBs in VEX is only done on unconditional branches, isn't it?
>
> Ah, this is wrong.
> An IRSB of course has multiple conditional side exits when chasing multiple BBs.
> But... this seems to be handled correctly in cg_main.c. Before every
> IRSB side exit (case Ist_Exit), the branch prediction simulation is called.
>
> Still. Most calls should be unconditional, and then the branch predictor
> is not called anyway, so there should be no difference between doing chasing
> or not.
>
>>> I do not think these are relevant for branch simulation?
>>>
>>> I actually didn't check both of these my assumptions, so I may be wrong.
>>
>> I can certainly say that for s390 almost all function calls are lost due
>> to chaining, so I needed this to get sane results on s390.
>
> For such a lost branch, can you check if this is a conditional or indirect
> branch? I wonder why the branch predictor is not called if chasing is done.
>
Its about unconditional direct branches (calls)
e.g.
==== SB 37 (evchecks 68) [tid 1] 0x4004e92 _dl_start+1274 /usr/lib64/ld-2.22.so+0x4e92
------------------------ Front end ------------------------
oi 3244(%r7),32
------ IMark(0x4004E92, 4, 0) ------
t0 = Add64(0xCAC:I64,GET:I64(248))
t1 = LDbe:I8(t0)
t2 = Or8(t1,0x20:I8)
PUT(352) = 0x0:I64
PUT(360) = 8Uto64(t2)
PUT(368) = 0x0:I64
PUT(376) = 0x0:I64
STbe(t0) = t2
PUT(336) = 0x4004E96:I64
larl %r2,.+142074
------ IMark(0x4004E96, 6, 0) ------
PUT(208) = 0x4027990:I64
PUT(336) = 0x4004E9C:I64
brasl %r14,.+29460
------ IMark(0x4004E9C, 6, 0) ------
PUT(304) = 0x4004EA2:I64
PUT(336) = 0x400C1B0:I64
<--- This branch becomes a nop IR-wise due to resteering.
ltg %r1,664(%r2)
------ IMark(0x400C1B0, 6, 0) ------
t4 = 0x298:I64
t3 = Add64(Add64(t4,GET:I64(208)),0x0:I64)
t5 = LDbe:I64(t3)
PUT(200) = t5
PUT(352) = 0xF:I64
PUT(360) = t5
PUT(368) = 0x0:I64
PUT(376) = 0x0:I64
PUT(336) = 0x400C1B6:I64
je .+104
------ IMark(0x400C1B6, 4, 0) ------
t6 = s390_calculate_cond[mcx=0x13]{0x8010ff188}(0x8:I64,GET:I64(352),GET:I64(360),GET:I64(368),GET:I64(376)):I32
if (CmpNE32(t6,0x0:I32)) { PUT(336) = 0x400C21E:I64; exit-Boring }
PUT(336) = 0x400C1BA:I64
PUT(336) = GET:I64(336); exit-Boring
can't show code due to extents > 1
|