rendered paste body(gdb) c
Continuing.
after : a,b: wrap( 2(a) ), wrap( 3(a) )
A==6(a)
test()
before: a,b: wrap( 2(a) ), wrap( 3(a) )
Breakpoint 1, wrap<adouble const>::mul (this=0x7fffffffe570, v=...) at adolc_test.cc:15
15 return x * v.x;
15: globalTapeVars.store[14] = 0
14: globalTapeVars.store[13] = 0
13: globalTapeVars.store[12] = 0
12: globalTapeVars.store[11] = 0
11: globalTapeVars.store[10] = 0
10: globalTapeVars.store[9] = 0
9: globalTapeVars.store[8] = 0
8: globalTapeVars.store[7] = 6
7: globalTapeVars.store[6] = 2
6: globalTapeVars.store[5] = 2
5: globalTapeVars.store[4] = 3
4: globalTapeVars.store[3] = 2
3: globalTapeVars.store[2] = 3
2: globalTapeVars.store[1] = 2
1: globalTapeVars.store[0] = 3
(gdb) s
operator* (x=..., y=...) at adouble.cpp:1001
1001 adub operator * ( const badouble& x, const badouble& y ) {
15: globalTapeVars.store[14] = 0
14: globalTapeVars.store[13] = 0
13: globalTapeVars.store[12] = 0
12: globalTapeVars.store[11] = 0
11: globalTapeVars.store[10] = 0
10: globalTapeVars.store[9] = 0
9: globalTapeVars.store[8] = 0
8: globalTapeVars.store[7] = 6
7: globalTapeVars.store[6] = 2
6: globalTapeVars.store[5] = 2
5: globalTapeVars.store[4] = 3
4: globalTapeVars.store[3] = 2
3: globalTapeVars.store[2] = 3
2: globalTapeVars.store[1] = 2
1: globalTapeVars.store[0] = 3
(gdb) frame 2
#2 0x0000000000401fb3 in test_ (a=..., b=...) at adolc_test.cc:48
48 cout << "checking for " << typeid (D).name() << endl;
(gdb) print a
$1 = {x = {<badouble> = {location = 5}, <No data fields>}}
(gdb) print b
$2 = {x = {<badouble> = {location = 4}, <No data fields>}}
(gdb) print A
$3 = {<badouble> = {location = 6}, <No data fields>}
(gdb) frame 0
#0 operator* (x=..., y=...) at adouble.cpp:1001
1001 adub operator * ( const badouble& x, const badouble& y ) {
(gdb) print x.location
$4 = 4
(gdb) print y.location
$5 = 6
(gdb)