diff --git a/debuginfo-tests/dexter-tests/aggregate-indirect-arg.cpp b/debuginfo-tests/dexter-tests/aggregate-indirect-arg.cpp --- a/debuginfo-tests/dexter-tests/aggregate-indirect-arg.cpp +++ b/debuginfo-tests/dexter-tests/aggregate-indirect-arg.cpp @@ -32,7 +32,7 @@ DexExpectProgramState({ 'frames': [ { - 'location': { 'lineno': 'foo' }, + 'location': { 'lineno': ref('foo') }, 'watches': { 'v.Data == 0': 'true', 'v.Kind': '2142' diff --git a/debuginfo-tests/dexter-tests/asan-deque.cpp b/debuginfo-tests/dexter-tests/asan-deque.cpp --- a/debuginfo-tests/dexter-tests/asan-deque.cpp +++ b/debuginfo-tests/dexter-tests/asan-deque.cpp @@ -41,8 +41,8 @@ } } -// DexExpectWatchValue('deq[0].a', '1234', on_line='first') -// DexExpectWatchValue('deq[1].a', '56789', on_line='first') +// DexExpectWatchValue('deq[0].a', '1234', on_line=ref('first')) +// DexExpectWatchValue('deq[1].a', '56789', on_line=ref('first')) -// DexExpectWatchValue('deq[0].a', '56789', '0', on_line='second') +// DexExpectWatchValue('deq[0].a', '56789', '0', on_line=ref('second')) diff --git a/debuginfo-tests/dexter-tests/asan.c b/debuginfo-tests/dexter-tests/asan.c --- a/debuginfo-tests/dexter-tests/asan.c +++ b/debuginfo-tests/dexter-tests/asan.c @@ -23,7 +23,7 @@ return 0; } -// DexExpectWatchValue('s.a[0]', '0', on_line='asan') -// DexExpectWatchValue('s.a[1]', '1', on_line='asan') -// DexExpectWatchValue('s.a[7]', '7', on_line='asan') +// DexExpectWatchValue('s.a[0]', '0', on_line=ref('asan')) +// DexExpectWatchValue('s.a[1]', '1', on_line=ref('asan')) +// DexExpectWatchValue('s.a[7]', '7', on_line=ref('asan')) diff --git a/debuginfo-tests/dexter-tests/ctor.cpp b/debuginfo-tests/dexter-tests/ctor.cpp --- a/debuginfo-tests/dexter-tests/ctor.cpp +++ b/debuginfo-tests/dexter-tests/ctor.cpp @@ -24,7 +24,7 @@ 'frames': [ { 'location': { - 'lineno': 'ctor_start' + 'lineno': ref('ctor_start') }, 'watches': { '*this': {'is_irretrievable': False} diff --git a/debuginfo-tests/dexter-tests/dbg-arg.c b/debuginfo-tests/dexter-tests/dbg-arg.c --- a/debuginfo-tests/dexter-tests/dbg-arg.c +++ b/debuginfo-tests/dexter-tests/dbg-arg.c @@ -48,7 +48,7 @@ DexExpectProgramState({ 'frames': [ { - 'location': { 'lineno': 'l_assign' }, + 'location': { 'lineno': ref('l_assign') }, 'watches': { '*mutex': { 'is_irretrievable': False } } diff --git a/debuginfo-tests/dexter-tests/deferred_globals.cpp b/debuginfo-tests/dexter-tests/deferred_globals.cpp --- a/debuginfo-tests/dexter-tests/deferred_globals.cpp +++ b/debuginfo-tests/dexter-tests/deferred_globals.cpp @@ -24,6 +24,6 @@ return d; // DexLabel("foo") } -// DexExpectWatchValue('d', '4', on_line='main') -// DexExpectWatchValue('d', '100', on_line='foo') +// DexExpectWatchValue('d', '4', on_line=ref('main')) +// DexExpectWatchValue('d', '100', on_line=ref('foo')) diff --git a/debuginfo-tests/dexter-tests/global-constant.cpp b/debuginfo-tests/dexter-tests/global-constant.cpp --- a/debuginfo-tests/dexter-tests/global-constant.cpp +++ b/debuginfo-tests/dexter-tests/global-constant.cpp @@ -21,10 +21,10 @@ return 0; } -// DexExpectWatchValue('TestPi', 3.140000104904175, on_line='stop') -// DexExpectWatchValue('S::TestCharA', 97, on_line='stop') -// DexExpectWatchValue('ENUM_NEG', -2147000000, on_line='stop') +// DexExpectWatchValue('TestPi', 3.140000104904175, on_line=ref('stop')) +// DexExpectWatchValue('S::TestCharA', 97, on_line=ref('stop')) +// DexExpectWatchValue('ENUM_NEG', -2147000000, on_line=ref('stop')) /* DexExpectProgramState({'frames': [{ - 'location': {'lineno' : 'stop'}, + 'location': {'lineno' : ref('stop')}, 'watches': {'ENUM_POS' : {'is_irretrievable': True}} }]}) */ diff --git a/debuginfo-tests/dexter-tests/hello.c b/debuginfo-tests/dexter-tests/hello.c --- a/debuginfo-tests/dexter-tests/hello.c +++ b/debuginfo-tests/dexter-tests/hello.c @@ -10,4 +10,4 @@ __debugbreak(); // DexLabel('stop') } -// DexExpectWatchValue('x', 42, on_line='stop') +// DexExpectWatchValue('x', 42, on_line=ref('stop')) diff --git a/debuginfo-tests/dexter-tests/inline-line-gap.cpp b/debuginfo-tests/dexter-tests/inline-line-gap.cpp --- a/debuginfo-tests/dexter-tests/inline-line-gap.cpp +++ b/debuginfo-tests/dexter-tests/inline-line-gap.cpp @@ -40,7 +40,7 @@ /* DexExpectProgramState({'frames':[ - {'function': 'inlineCrashFrame', 'location':{'lineno' : 'stop'} }, + {'function': 'inlineCrashFrame', 'location':{'lineno' : ref('stop')} }, {'function': 'callerOfInlineCrashFrame'}, {'function': 'main'} ]}) diff --git a/debuginfo-tests/dexter-tests/memvars/bitcast.c b/debuginfo-tests/dexter-tests/memvars/bitcast.c --- a/debuginfo-tests/dexter-tests/memvars/bitcast.c +++ b/debuginfo-tests/dexter-tests/memvars/bitcast.c @@ -72,6 +72,6 @@ return 0; // DexLabel('s4') } -// DexExpectWatchValue('x', '5', from_line='s1', to_line='s4') -// DexExpectWatchValue('y', '5', from_line='s2', to_line='s4') -// DexExpectWatchValue('z', '5', from_line='s3', to_line='s4') +// DexExpectWatchValue('x', '5', from_line=ref('s1'), to_line=ref('s4')) +// DexExpectWatchValue('y', '5', from_line=ref('s2'), to_line=ref('s4')) +// DexExpectWatchValue('z', '5', from_line=ref('s3'), to_line=ref('s4')) diff --git a/debuginfo-tests/dexter-tests/memvars/const-branch.c b/debuginfo-tests/dexter-tests/memvars/const-branch.c --- a/debuginfo-tests/dexter-tests/memvars/const-branch.c +++ b/debuginfo-tests/dexter-tests/memvars/const-branch.c @@ -48,5 +48,5 @@ return fun(5); } -// DexExpectWatchValue('param', '5', from_line='s1', to_line='s2') +// DexExpectWatchValue('param', '5', from_line=ref('s1'), to_line=ref('s2')) diff --git a/debuginfo-tests/dexter-tests/memvars/ctrl-flow.c b/debuginfo-tests/dexter-tests/memvars/ctrl-flow.c --- a/debuginfo-tests/dexter-tests/memvars/ctrl-flow.c +++ b/debuginfo-tests/dexter-tests/memvars/ctrl-flow.c @@ -30,5 +30,5 @@ } //// fun(1) fun(0) -// DexExpectWatchValue('local', '0', '0', on_line='s1') -// DexExpectWatchValue('local', '2', '1', on_line='s2') +// DexExpectWatchValue('local', '0', '0', on_line=ref('s1')) +// DexExpectWatchValue('local', '2', '1', on_line=ref('s2')) diff --git a/debuginfo-tests/dexter-tests/memvars/implicit-ptr.c b/debuginfo-tests/dexter-tests/memvars/implicit-ptr.c --- a/debuginfo-tests/dexter-tests/memvars/implicit-ptr.c +++ b/debuginfo-tests/dexter-tests/memvars/implicit-ptr.c @@ -40,6 +40,6 @@ return fun(5); } -// DexExpectWatchValue('param', 5, from_line='s1', to_line='s4') -// DexExpectWatchValue('*pa', 5, on_line='s2') -// DexExpectWatchValue('*pb', 5, on_line='s3') +// DexExpectWatchValue('param', 5, from_line=ref('s1'), to_line=ref('s4')) +// DexExpectWatchValue('*pa', 5, on_line=ref('s2')) +// DexExpectWatchValue('*pb', 5, on_line=ref('s3')) diff --git a/debuginfo-tests/dexter-tests/memvars/inline-escaping-function.c b/debuginfo-tests/dexter-tests/memvars/inline-escaping-function.c --- a/debuginfo-tests/dexter-tests/memvars/inline-escaping-function.c +++ b/debuginfo-tests/dexter-tests/memvars/inline-escaping-function.c @@ -42,4 +42,4 @@ return fun(5); } -// DexExpectWatchValue('param', 10, on_line='s0') +// DexExpectWatchValue('param', 10, on_line=ref('s0')) diff --git a/debuginfo-tests/dexter-tests/memvars/inlining-dse.c b/debuginfo-tests/dexter-tests/memvars/inlining-dse.c --- a/debuginfo-tests/dexter-tests/memvars/inlining-dse.c +++ b/debuginfo-tests/dexter-tests/memvars/inlining-dse.c @@ -32,13 +32,13 @@ /* # Expect param == 5 before stepping through inlined 'use'. -DexExpectWatchValue('param', '5', on_line='fun1') +DexExpectWatchValue('param', '5', on_line=ref('fun1')) # Expect param == 255 after assignment in inlined frame 'use'. DexExpectProgramState({ 'frames': [ { 'function': 'use', - 'location': { 'lineno': 'use1' }, + 'location': { 'lineno': ref('use1') }, }, { 'function': 'fun', 'location': { 'lineno': 20 }, @@ -48,5 +48,5 @@ }) # Expect param == 255 after inlined call to 'use'. -DexExpectWatchValue('param', '255', on_line='fun2') +DexExpectWatchValue('param', '255', on_line=ref('fun2')) */ diff --git a/debuginfo-tests/dexter-tests/memvars/inlining.c b/debuginfo-tests/dexter-tests/memvars/inlining.c --- a/debuginfo-tests/dexter-tests/memvars/inlining.c +++ b/debuginfo-tests/dexter-tests/memvars/inlining.c @@ -23,4 +23,4 @@ fun(5); } -// DexExpectWatchValue('param', '5', from_line='s1', to_line='s2') +// DexExpectWatchValue('param', '5', from_line=ref('s1'), to_line=ref('s2')) diff --git a/debuginfo-tests/dexter-tests/memvars/loop.c b/debuginfo-tests/dexter-tests/memvars/loop.c --- a/debuginfo-tests/dexter-tests/memvars/loop.c +++ b/debuginfo-tests/dexter-tests/memvars/loop.c @@ -52,5 +52,5 @@ return fun(5); } -// DexExpectWatchValue('*p', 5, 5, 5, 5, 5, on_line='s1') -// DexExpectWatchValue('param', 5, from_line='s2', to_line='s3') +// DexExpectWatchValue('*p', 5, 5, 5, 5, 5, on_line=ref('s1')) +// DexExpectWatchValue('param', 5, from_line=ref('s2'), to_line=ref('s3')) diff --git a/debuginfo-tests/dexter-tests/memvars/merged-store.c b/debuginfo-tests/dexter-tests/memvars/merged-store.c --- a/debuginfo-tests/dexter-tests/memvars/merged-store.c +++ b/debuginfo-tests/dexter-tests/memvars/merged-store.c @@ -40,4 +40,4 @@ return fun(5, 20); } -// DexExpectWatchValue('parama', 20, on_line='s0') +// DexExpectWatchValue('parama', 20, on_line=ref('s0')) diff --git a/debuginfo-tests/dexter-tests/memvars/ptr-to.c b/debuginfo-tests/dexter-tests/memvars/ptr-to.c --- a/debuginfo-tests/dexter-tests/memvars/ptr-to.c +++ b/debuginfo-tests/dexter-tests/memvars/ptr-to.c @@ -26,10 +26,10 @@ } -// DexExpectWatchValue('local', 0xA, on_line='s1') -// DexExpectWatchValue('local', 0xB, on_line='s2') -// DexExpectWatchValue('*plocal', 0xA, on_line='s1') -// DexExpectWatchValue('*plocal', 0xB, on_line='s2') +// DexExpectWatchValue('local', 0xA, on_line=ref('s1')) +// DexExpectWatchValue('local', 0xB, on_line=ref('s2')) +// DexExpectWatchValue('*plocal', 0xA, on_line=ref('s1')) +// DexExpectWatchValue('*plocal', 0xB, on_line=ref('s2')) //// Ideally we should be able to observe the dead store to local (0xB) through //// plocal here. -// DexExpectWatchValue('(local == *plocal)', 'true', from_line='s1', to_line='s2') +// DexExpectWatchValue('(local == *plocal)', 'true', from_line=ref('s1'), to_line=ref('s2')) diff --git a/debuginfo-tests/dexter-tests/memvars/struct-dse.c b/debuginfo-tests/dexter-tests/memvars/struct-dse.c --- a/debuginfo-tests/dexter-tests/memvars/struct-dse.c +++ b/debuginfo-tests/dexter-tests/memvars/struct-dse.c @@ -29,5 +29,5 @@ return 0; // DexLabel('s3') } -// DexExpectWatchValue('nums.c', '1', on_line='s1') -// DexExpectWatchValue('nums.c', '2', from_line='s2', to_line='s3') +// DexExpectWatchValue('nums.c', '1', on_line=ref('s1')) +// DexExpectWatchValue('nums.c', '2', from_line=ref('s2'), to_line=ref('s3')) diff --git a/debuginfo-tests/dexter-tests/memvars/unused-merged-value.c b/debuginfo-tests/dexter-tests/memvars/unused-merged-value.c --- a/debuginfo-tests/dexter-tests/memvars/unused-merged-value.c +++ b/debuginfo-tests/dexter-tests/memvars/unused-merged-value.c @@ -36,7 +36,7 @@ return fun(5, 20); } -// DexExpectWatchValue('parama', 20, on_line='s0') +// DexExpectWatchValue('parama', 20, on_line=ref('s0')) // // NOTE: the dexter command uses --fail-lt 0.1 (instead of the standard 1.0) // because seeing 'optimized out' would still be a win; it's the best we can do diff --git a/debuginfo-tests/dexter-tests/namespace.cpp b/debuginfo-tests/dexter-tests/namespace.cpp --- a/debuginfo-tests/dexter-tests/namespace.cpp +++ b/debuginfo-tests/dexter-tests/namespace.cpp @@ -20,5 +20,5 @@ return 0; } -// DexExpectWatchValue('monkey::ape', 32, on_line='main') +// DexExpectWatchValue('monkey::ape', 32, on_line=ref('main')) diff --git a/debuginfo-tests/dexter-tests/nrvo-string.cpp b/debuginfo-tests/dexter-tests/nrvo-string.cpp --- a/debuginfo-tests/dexter-tests/nrvo-string.cpp +++ b/debuginfo-tests/dexter-tests/nrvo-string.cpp @@ -51,6 +51,6 @@ get_string2(); } -// DexExpectWatchValue('output.i', 3, on_line='string-nrvo') -// DexExpectWatchValue('output.i', 5, on_line='string2-nrvo') +// DexExpectWatchValue('output.i', 3, on_line=ref('string-nrvo')) +// DexExpectWatchValue('output.i', 5, on_line=ref('string2-nrvo')) diff --git a/debuginfo-tests/dexter-tests/nrvo.cpp b/debuginfo-tests/dexter-tests/nrvo.cpp --- a/debuginfo-tests/dexter-tests/nrvo.cpp +++ b/debuginfo-tests/dexter-tests/nrvo.cpp @@ -36,5 +36,5 @@ get_string2(); } -// DexExpectWatchValue('result.i', 3, on_line='readresult1') -// DexExpectWatchValue('result.i', 5, on_line='readresult2') +// DexExpectWatchValue('result.i', 3, on_line=ref('readresult1')) +// DexExpectWatchValue('result.i', 5, on_line=ref('readresult2')) diff --git a/debuginfo-tests/dexter-tests/optnone-fastmath.cpp b/debuginfo-tests/dexter-tests/optnone-fastmath.cpp --- a/debuginfo-tests/dexter-tests/optnone-fastmath.cpp +++ b/debuginfo-tests/dexter-tests/optnone-fastmath.cpp @@ -23,8 +23,8 @@ result = A / 10.f; // DexLabel('fdiv_assign') return result; // DexLabel('fdiv_ret') } -// DexExpectWatchValue('A', 4, on_line='fdiv_assign') -// DexExpectWatchValue('result', '0.400000006', on_line='fdiv_ret') +// DexExpectWatchValue('A', 4, on_line=ref('fdiv_assign')) +// DexExpectWatchValue('result', '0.400000006', on_line=ref('fdiv_ret')) //// (A * B) - (A * C) ==> A * (B - C) __attribute__((optnone)) @@ -35,9 +35,9 @@ result = op1 - op2; // DexLabel('distributivity_result') return result; // DexLabel('distributivity_ret') } -// DexExpectWatchValue('op1', '20', on_line='distributivity_op2') -// DexExpectWatchValue('op2', '24', on_line='distributivity_result') -// DexExpectWatchValue('result', '-4', on_line='distributivity_ret') +// DexExpectWatchValue('op1', '20', on_line=ref('distributivity_op2')) +// DexExpectWatchValue('op2', '24', on_line=ref('distributivity_result')) +// DexExpectWatchValue('result', '-4', on_line=ref('distributivity_ret')) //// (A + B) + C == A + (B + C) //// therefore, ((A + B) + C) + (A + (B + C))) @@ -55,9 +55,9 @@ result = op1 + op2; // DexLabel('associativity_result') return result; // DexLabel('associativity_ret') } -// DexExpectWatchValue('op1', '9', '15', from_line='associativity_op1', to_line='associativity_result') -// DexExpectWatchValue('op2', '11', '15', from_line='associativity_op1', to_line='associativity_result') -// DexExpectWatchValue('result', '30', on_line='associativity_ret') +// DexExpectWatchValue('op1', '9', '15', from_line=ref('associativity_op1'), to_line=ref('associativity_result')) +// DexExpectWatchValue('op2', '11', '15', from_line=ref('associativity_op1'), to_line=ref('associativity_result')) +// DexExpectWatchValue('result', '30', on_line=ref('associativity_ret')) //// With fastmath, the ordering of instructions doesn't matter //// since we work under the assumption that there is no loss @@ -76,9 +76,9 @@ result -= 10.0f; return result; // DexLabel('fp_operations_ret') } -// DexExpectWatchValue('A', '8.25', on_line='fp_operations_result') -// DexExpectWatchValue('B', '26.3999996', on_line='fp_operations_result') -// DexExpectWatchValue('result', '18.25', '44.6500015', '34.6500015', from_line='fp_operations_add', to_line='fp_operations_ret') +// DexExpectWatchValue('A', '8.25', on_line=ref('fp_operations_result')) +// DexExpectWatchValue('B', '26.3999996', on_line=ref('fp_operations_result')) +// DexExpectWatchValue('result', '18.25', '44.6500015', '34.6500015', from_line=ref('fp_operations_add'), to_line=ref('fp_operations_ret')) //// Again, this is a simple return A + B. //// Clang is unable to spot the opportunity to fold the code sequence. @@ -89,10 +89,10 @@ result -= C; // DexLabel('fp_operations_2_subtract') return result; // DexLabel('fp_operations_2_ret') } -// DexExpectWatchValue('A', '9.11999988', on_line='fp_operations_2_result') -// DexExpectWatchValue('B', '61.050003', on_line='fp_operations_2_result') -// DexExpectWatchValue('C', '1002.11102', on_line='fp_operations_2_result') -// DexExpectWatchValue('result', '1072.28101', '70.1699829', from_line='fp_operations_2_subtract', to_line='fp_operations_2_ret') +// DexExpectWatchValue('A', '9.11999988', on_line=ref('fp_operations_2_result')) +// DexExpectWatchValue('B', '61.050003', on_line=ref('fp_operations_2_result')) +// DexExpectWatchValue('C', '1002.11102', on_line=ref('fp_operations_2_result')) +// DexExpectWatchValue('result', '1072.28101', '70.1699829', from_line=ref('fp_operations_2_subtract'), to_line=ref('fp_operations_2_ret')) int main() { float result = test_fdiv(4.0f); diff --git a/debuginfo-tests/dexter-tests/optnone-loops.cpp b/debuginfo-tests/dexter-tests/optnone-loops.cpp --- a/debuginfo-tests/dexter-tests/optnone-loops.cpp +++ b/debuginfo-tests/dexter-tests/optnone-loops.cpp @@ -22,9 +22,9 @@ dest[i] = src[i]; // DexLabel('target_simple_memcpy_loop') } -// DexLimitSteps('i', 0, 4, 8, on_line='target_simple_memcpy_loop') -// DexExpectWatchValue('nelems', '16', on_line='target_simple_memcpy_loop') -// DexExpectWatchValue('src[i]', '3', '7', '1', on_line='target_simple_memcpy_loop') +// DexLimitSteps('i', 0, 4, 8, on_line=ref('target_simple_memcpy_loop')) +// DexExpectWatchValue('nelems', '16', on_line=ref('target_simple_memcpy_loop')) +// DexExpectWatchValue('src[i]', '3', '7', '1', on_line=ref('target_simple_memcpy_loop')) // A trivial loop that could be optimized into a builtin memcpy @@ -35,9 +35,9 @@ dest[i] = src[i]; // DexLabel('target_trivial_memcpy_loop') } -// DexLimitSteps('i', 3, 7, 9, 14, 15, on_line='target_trivial_memcpy_loop') -// DexExpectWatchValue('i', 3, 7, 9, 14, 15, on_line='target_trivial_memcpy_loop') -// DexExpectWatchValue('dest[i-1] == src[i-1]', 'true', on_line='target_trivial_memcpy_loop') +// DexLimitSteps('i', 3, 7, 9, 14, 15, on_line=ref('target_trivial_memcpy_loop')) +// DexExpectWatchValue('i', 3, 7, 9, 14, 15, on_line=ref('target_trivial_memcpy_loop')) +// DexExpectWatchValue('dest[i-1] == src[i-1]', 'true', on_line=ref('target_trivial_memcpy_loop')) __attribute__((always_inline)) int foo(int a) { return a + 5; } @@ -49,16 +49,16 @@ dest[i] = foo(src[i]); // DexLabel('target_nonleaf_function_with_loop') } -// DexLimitSteps('i', 1, on_line='target_nonleaf_function_with_loop') -// DexExpectWatchValue('dest[0]', '8', on_line='target_nonleaf_function_with_loop') -// DexExpectWatchValue('dest[1]', '4', on_line='target_nonleaf_function_with_loop') -// DexExpectWatchValue('dest[2]', '5', on_line='target_nonleaf_function_with_loop') -// DexExpectWatchValue('src[0]', '8', on_line='target_nonleaf_function_with_loop') -// DexExpectWatchValue('src[1]', '4', on_line='target_nonleaf_function_with_loop') -// DexExpectWatchValue('src[2]', '5', on_line='target_nonleaf_function_with_loop') +// DexLimitSteps('i', 1, on_line=ref('target_nonleaf_function_with_loop')) +// DexExpectWatchValue('dest[0]', '8', on_line=ref('target_nonleaf_function_with_loop')) +// DexExpectWatchValue('dest[1]', '4', on_line=ref('target_nonleaf_function_with_loop')) +// DexExpectWatchValue('dest[2]', '5', on_line=ref('target_nonleaf_function_with_loop')) +// DexExpectWatchValue('src[0]', '8', on_line=ref('target_nonleaf_function_with_loop')) +// DexExpectWatchValue('src[1]', '4', on_line=ref('target_nonleaf_function_with_loop')) +// DexExpectWatchValue('src[2]', '5', on_line=ref('target_nonleaf_function_with_loop')) -// DexExpectWatchValue('src[1] == dest[1]', 'true', on_line='target_nonleaf_function_with_loop') -// DexExpectWatchValue('src[2] == dest[2]', 'true', on_line='target_nonleaf_function_with_loop') +// DexExpectWatchValue('src[1] == dest[1]', 'true', on_line=ref('target_nonleaf_function_with_loop')) +// DexExpectWatchValue('src[2] == dest[2]', 'true', on_line=ref('target_nonleaf_function_with_loop')) // This entire function could be optimized into a @@ -72,8 +72,8 @@ return i; } -// DexLimitSteps('i', 8, 16, on_line='target_counting_loop') -// DexExpectWatchValue('i', 8, 16, on_line='target_counting_loop') +// DexLimitSteps('i', 8, 16, on_line=ref('target_counting_loop')) +// DexExpectWatchValue('i', 8, 16, on_line=ref('target_counting_loop')) // This loop could be rotated. @@ -105,10 +105,10 @@ return result; // DexLabel('target_loop_rotate_test_ret') } -// DexLimitSteps('result', 13, on_line='target_loop_rotate_test') -// DexExpectWatchValue('src[count]', 13, on_line='target_loop_rotate_test') -// DexLimitSteps('result', 158, on_line='target_loop_rotate_test_ret') -// DexExpectWatchValue('result', 158, on_line='target_loop_rotate_test_ret') +// DexLimitSteps('result', 13, on_line=ref('target_loop_rotate_test')) +// DexExpectWatchValue('src[count]', 13, on_line=ref('target_loop_rotate_test')) +// DexLimitSteps('result', 158, on_line=ref('target_loop_rotate_test_ret')) +// DexExpectWatchValue('result', 158, on_line=ref('target_loop_rotate_test_ret')) typedef int *intptr __attribute__((aligned(16))); @@ -133,15 +133,15 @@ } } -// DexLimitSteps('count', 4, 8, 12, 16, from_line='target_loop_vectorize_test', to_line='target_loop_vectorize_test_9') -// DexExpectWatchValue('tempArray[count] == src[count]', 'true', on_line='target_loop_vectorize_test_2') -// DexExpectWatchValue('tempArray[count+1] == src[count+1]', 'true', on_line='target_loop_vectorize_test_3') -// DexExpectWatchValue('tempArray[count+2] == src[count+2]', 'true', on_line='target_loop_vectorize_test_4') -// DexExpectWatchValue('tempArray[count+3] == src[count+3]', 'true', on_line='target_loop_vectorize_test_5') -// DexExpectWatchValue('dest[count] == tempArray[count]', 'true', on_line='target_loop_vectorize_test_6') -// DexExpectWatchValue('dest[count+1] == tempArray[count+1]', 'true', on_line='target_loop_vectorize_test_7') -// DexExpectWatchValue('dest[count+2] == tempArray[count+2]', 'true', on_line='target_loop_vectorize_test_8') -// DexExpectWatchValue('dest[count+3] == tempArray[count+3]', 'true', on_line='target_loop_vectorize_test_9') +// DexLimitSteps('count', 4, 8, 12, 16, from_line=ref('target_loop_vectorize_test'), to_line=ref('target_loop_vectorize_test_9')) +// DexExpectWatchValue('tempArray[count] == src[count]', 'true', on_line=ref('target_loop_vectorize_test_2')) +// DexExpectWatchValue('tempArray[count+1] == src[count+1]', 'true', on_line=ref('target_loop_vectorize_test_3')) +// DexExpectWatchValue('tempArray[count+2] == src[count+2]', 'true', on_line=ref('target_loop_vectorize_test_4')) +// DexExpectWatchValue('tempArray[count+3] == src[count+3]', 'true', on_line=ref('target_loop_vectorize_test_5')) +// DexExpectWatchValue('dest[count] == tempArray[count]', 'true', on_line=ref('target_loop_vectorize_test_6')) +// DexExpectWatchValue('dest[count+1] == tempArray[count+1]', 'true', on_line=ref('target_loop_vectorize_test_7')) +// DexExpectWatchValue('dest[count+2] == tempArray[count+2]', 'true', on_line=ref('target_loop_vectorize_test_8')) +// DexExpectWatchValue('dest[count+3] == tempArray[count+3]', 'true', on_line=ref('target_loop_vectorize_test_9')) int main() { diff --git a/debuginfo-tests/dexter-tests/optnone-simple-functions.cpp b/debuginfo-tests/dexter-tests/optnone-simple-functions.cpp --- a/debuginfo-tests/dexter-tests/optnone-simple-functions.cpp +++ b/debuginfo-tests/dexter-tests/optnone-simple-functions.cpp @@ -20,9 +20,9 @@ return test1_result; // DexExpectStepOrder(2) // DexLabel('test1_end') } -// DexExpectWatchValue('test1_a', 3, from_line='test1_start', to_line='test1_end') -// DexExpectWatchValue('test1_b', 4, from_line='test1_start', to_line='test1_end') -// DexExpectWatchValue('test1_result', 0, 7, from_line='test1_start', to_line='test1_end') +// DexExpectWatchValue('test1_a', 3, from_line=ref('test1_start'), to_line=ref('test1_end')) +// DexExpectWatchValue('test1_b', 4, from_line=ref('test1_start'), to_line=ref('test1_end')) +// DexExpectWatchValue('test1_result', 0, 7, from_line=ref('test1_start'), to_line=ref('test1_end')) __attribute__((optnone)) int test2(int test2_a, int test2_b) { @@ -31,9 +31,9 @@ return test2_a << 2; // DexExpectStepOrder(4) // DexLabel('test2_end') } -// DexExpectWatchValue('test2_a', 1, from_line='test2_start', to_line='test2_end') -// DexExpectWatchValue('test2_b', 2, from_line='test2_start', to_line='test2_end') -// DexExpectWatchValue('test2_result', 4, from_line='test2_start', to_line='test2_end') +// DexExpectWatchValue('test2_a', 1, from_line=ref('test2_start'), to_line=ref('test2_end')) +// DexExpectWatchValue('test2_b', 2, from_line=ref('test2_start'), to_line=ref('test2_end')) +// DexExpectWatchValue('test2_result', 4, from_line=ref('test2_start'), to_line=ref('test2_end')) __attribute__((optnone)) int test3(int test3_a, int test3_b) { @@ -47,10 +47,10 @@ return test3_temp1; // DexExpectStepOrder(8) // DexLabel('test3_end') } -// DexExpectWatchValue('test3_a', 5, from_line='test3_start', to_line='test3_end') -// DexExpectWatchValue('test3_b', 6, from_line='test3_start', to_line='test3_end') -// DexExpectWatchValue('test3_temp1', 0, 10, from_line='test3_start', to_line='test3_end') -// DexExpectWatchValue('test3_temp2', 0, 11, from_line='test3_start', to_line='test3_end') +// DexExpectWatchValue('test3_a', 5, from_line=ref('test3_start'), to_line=ref('test3_end')) +// DexExpectWatchValue('test3_b', 6, from_line=ref('test3_start'), to_line=ref('test3_end')) +// DexExpectWatchValue('test3_temp1', 0, 10, from_line=ref('test3_start'), to_line=ref('test3_end')) +// DexExpectWatchValue('test3_temp2', 0, 11, from_line=ref('test3_start'), to_line=ref('test3_end')) unsigned num_iterations = 4; @@ -73,10 +73,10 @@ return (val1 > val2) ? val2 : val1; // DexExpectStepOrder(20) // DexLabel('test4_end') } -// DexExpectWatchValue('test4_a', 1, from_line='test4_start', to_line='test4_end') -// DexExpectWatchValue('test4_b', 9, from_line='test4_start', to_line='test4_end') -// DexExpectWatchValue('val1', 0, 9, 8, 7, 6, 5, from_line='test4_start', to_line='test4_end') -// DexExpectWatchValue('val2', 0, 9, 18, 9, 10, 5, 7, 10, 5, 9, from_line='test4_start', to_line='test4_end') +// DexExpectWatchValue('test4_a', 1, from_line=ref('test4_start'), to_line=ref('test4_end')) +// DexExpectWatchValue('test4_b', 9, from_line=ref('test4_start'), to_line=ref('test4_end')) +// DexExpectWatchValue('val1', 0, 9, 8, 7, 6, 5, from_line=ref('test4_start'), to_line=ref('test4_end')) +// DexExpectWatchValue('val2', 0, 9, 18, 9, 10, 5, 7, 10, 5, 9, from_line=ref('test4_start'), to_line=ref('test4_end')) __attribute__((optnone)) int test5(int test5_val) { @@ -87,8 +87,8 @@ return c ? test5_val : test5_val; // DexExpectStepOrder(24) // DexLabel('test5_end') } -// DexExpectWatchValue('test5_val', 7, from_line='test5_start', to_line='test5_end') -// DexExpectWatchValue('c', 1, 5, from_line='test5_start', to_line='test5_end') +// DexExpectWatchValue('test5_val', 7, from_line=ref('test5_start'), to_line=ref('test5_end')) +// DexExpectWatchValue('c', 1, 5, from_line=ref('test5_start'), to_line=ref('test5_end')) int main() { int main_result = 0; @@ -101,4 +101,4 @@ return main_result; // DexLabel('main_end') } -// DexExpectWatchValue('main_result', 0, 7, 11, 21, 26, 33, from_line='main_start', to_line='main_end') +// DexExpectWatchValue('main_result', 0, 7, 11, 21, 26, 33, from_line=ref('main_start'), to_line=ref('main_end')) diff --git a/debuginfo-tests/dexter-tests/optnone-struct-and-methods.cpp b/debuginfo-tests/dexter-tests/optnone-struct-and-methods.cpp --- a/debuginfo-tests/dexter-tests/optnone-struct-and-methods.cpp +++ b/debuginfo-tests/dexter-tests/optnone-struct-and-methods.cpp @@ -67,21 +67,21 @@ A() { __builtin_memset(this, 0xFF, sizeof(*this)); } //DexLabel('break_0') - // DexExpectWatchValue('a', '-1', on_line='break_0') + // DexExpectWatchValue('a', '-1', on_line=ref('break_0')) //// Check b is NaN by comparing it to itself. - // DexExpectWatchValue('this->b == this->b', 'false', on_line='break_0') - // DexExpectWatchValue('_data.a.raw_ptr == -1', 'true', on_line='break_0') - // DexExpectWatchValue('_data.a.float_ptr == -1', 'true', on_line='break_0') - // DexExpectWatchValue('_data.a.float_ptr == -1', 'true', on_line='break_0') - // DexExpectWatchValue('a_global_ptr[0]', 0xcafebabe, on_line='break_0') - // DexExpectWatchValue('a_global_ptr[1]', 0xfeedbeef, on_line='break_0') + // DexExpectWatchValue('this->b == this->b', 'false', on_line=ref('break_0')) + // DexExpectWatchValue('_data.a.raw_ptr == -1', 'true', on_line=ref('break_0')) + // DexExpectWatchValue('_data.a.float_ptr == -1', 'true', on_line=ref('break_0')) + // DexExpectWatchValue('_data.a.float_ptr == -1', 'true', on_line=ref('break_0')) + // DexExpectWatchValue('a_global_ptr[0]', 0xcafebabe, on_line=ref('break_0')) + // DexExpectWatchValue('a_global_ptr[1]', 0xfeedbeef, on_line=ref('break_0')) __attribute__((optnone)) ~A() { *getOtherData()->a.long_ptr = 0xADDF00DL; } //DexLabel('break_1') - // DexExpectWatchValue('_data.a.raw_ptr == a_global_ptr', 'true', on_line='break_1') - // DexExpectWatchValue('a_global_ptr[0]', 0xaddf00d, on_line='break_1') + // DexExpectWatchValue('_data.a.raw_ptr == a_global_ptr', 'true', on_line=ref('break_1')) + // DexExpectWatchValue('a_global_ptr[0]', 0xaddf00d, on_line=ref('break_1')) __attribute__((optnone)) long getData() { @@ -89,8 +89,8 @@ setOtherData(); return getOtherData()->a.long_ptr[1]; //DexLabel('break_2') } - // DexExpectWatchValue('_data.b.other_b', 'B_VALUE', on_line='break_2') - // DexExpectWatchValue('_data.b.other_other_b', 'A_VALUE', on_line='break_2') + // DexExpectWatchValue('_data.b.other_b', 'B_VALUE', on_line=ref('break_2')) + // DexExpectWatchValue('_data.b.other_other_b', 'A_VALUE', on_line=ref('break_2')) }; } // anonymous namespace diff --git a/debuginfo-tests/dexter-tests/optnone-vectors-and-functions.cpp b/debuginfo-tests/dexter-tests/optnone-vectors-and-functions.cpp --- a/debuginfo-tests/dexter-tests/optnone-vectors-and-functions.cpp +++ b/debuginfo-tests/dexter-tests/optnone-vectors-and-functions.cpp @@ -30,26 +30,26 @@ T tmp2 = tmp + y; return tmp; // DexLabel('break_1') } -// DexLimitSteps('1', '1', from_line='break_0', to_line='break_1') +// DexLimitSteps('1', '1', from_line=ref('break_0'), to_line=ref('break_1')) //// FIXME: gdb can print this but lldb cannot. Perhaps PR42920? -// \DexExpectWatchValue('TypeTraits::NumElements', 4, on_line='break_0') -// \DexExpectWatchValue('TypeTraits::UnusedField', 0xdeadbeef, on_line='break_0') -// DexExpectWatchValue('x[0]', 1, on_line='break_0') -// DexExpectWatchValue('x[1]', 2, on_line='break_0') -// DexExpectWatchValue('x[2]', 3, on_line='break_0') -// DexExpectWatchValue('x[3]', 4, on_line='break_0') -// DexExpectWatchValue('y[0]', 5, on_line='break_0') -// DexExpectWatchValue('y[1]', 6, on_line='break_0') -// DexExpectWatchValue('y[2]', 7, on_line='break_0') -// DexExpectWatchValue('y[3]', 8, on_line='break_0') -// DexExpectWatchValue('tmp[0]', 6, on_line='break_1') -// DexExpectWatchValue('tmp[1]', 8, on_line='break_1') -// DexExpectWatchValue('tmp[2]', 10, on_line='break_1') -// DexExpectWatchValue('tmp[3]', 12, on_line='break_1') -// DexExpectWatchValue('tmp2[0]', 11, on_line='break_1') -// DexExpectWatchValue('tmp2[1]', 14, on_line='break_1') -// DexExpectWatchValue('tmp2[2]', 17, on_line='break_1') -// DexExpectWatchValue('tmp2[3]', 20, on_line='break_1') +// \DexExpectWatchValue('TypeTraits::NumElements', 4, on_line=ref('break_0')) +// \DexExpectWatchValue('TypeTraits::UnusedField', 0xdeadbeef, on_line=ref('break_0')) +// DexExpectWatchValue('x[0]', 1, on_line=ref('break_0')) +// DexExpectWatchValue('x[1]', 2, on_line=ref('break_0')) +// DexExpectWatchValue('x[2]', 3, on_line=ref('break_0')) +// DexExpectWatchValue('x[3]', 4, on_line=ref('break_0')) +// DexExpectWatchValue('y[0]', 5, on_line=ref('break_0')) +// DexExpectWatchValue('y[1]', 6, on_line=ref('break_0')) +// DexExpectWatchValue('y[2]', 7, on_line=ref('break_0')) +// DexExpectWatchValue('y[3]', 8, on_line=ref('break_0')) +// DexExpectWatchValue('tmp[0]', 6, on_line=ref('break_1')) +// DexExpectWatchValue('tmp[1]', 8, on_line=ref('break_1')) +// DexExpectWatchValue('tmp[2]', 10, on_line=ref('break_1')) +// DexExpectWatchValue('tmp[3]', 12, on_line=ref('break_1')) +// DexExpectWatchValue('tmp2[0]', 11, on_line=ref('break_1')) +// DexExpectWatchValue('tmp2[1]', 14, on_line=ref('break_1')) +// DexExpectWatchValue('tmp2[2]', 17, on_line=ref('break_1')) +// DexExpectWatchValue('tmp2[3]', 20, on_line=ref('break_1')) template __attribute__((optnone)) @@ -64,26 +64,26 @@ tmp[0] >>= TypeTraits::MysteryNumber; return tmp; // DexLabel('break_5') } -// DexLimitSteps('1', '1', on_line='break_2') -// DexExpectWatchValue('x[0]', 6, on_line='break_2') -// DexExpectWatchValue('x[1]', 8, on_line='break_2') -// DexExpectWatchValue('x[2]', 10, on_line='break_2') -// DexExpectWatchValue('x[3]', 12, on_line='break_2') -// DexExpectWatchValue('y[0]', 5, on_line='break_2') -// DexExpectWatchValue('y[1]', 6, on_line='break_2') -// DexExpectWatchValue('y[2]', 7, on_line='break_2') -// DexExpectWatchValue('y[3]', 8, on_line='break_2') -// DexExpectWatchValue('tmp[0]', 6, on_line='break_2') -// DexExpectWatchValue('tmp[1]', 8, on_line='break_2') -// DexExpectWatchValue('tmp[2]', 10, on_line='break_2') -// DexExpectWatchValue('tmp[3]', 12, on_line='break_2') -// DexLimitSteps('i', 3, on_line='break_3') -// DexExpectWatchValue('tmp[0]', 63, on_line='break_3') -// DexExpectWatchValue('tmp[1]', 94, on_line='break_3') -// DexExpectWatchValue('tmp[2]', 95, on_line='break_3') -// DexExpectWatchValue('tmp[3]', 120, on_line='break_3') -// DexLimitSteps('i', 3, on_line='break_5') -// DexExpectWatchValue('tmp[0]', 15, on_line='break_5') +// DexLimitSteps('1', '1', on_line=ref('break_2')) +// DexExpectWatchValue('x[0]', 6, on_line=ref('break_2')) +// DexExpectWatchValue('x[1]', 8, on_line=ref('break_2')) +// DexExpectWatchValue('x[2]', 10, on_line=ref('break_2')) +// DexExpectWatchValue('x[3]', 12, on_line=ref('break_2')) +// DexExpectWatchValue('y[0]', 5, on_line=ref('break_2')) +// DexExpectWatchValue('y[1]', 6, on_line=ref('break_2')) +// DexExpectWatchValue('y[2]', 7, on_line=ref('break_2')) +// DexExpectWatchValue('y[3]', 8, on_line=ref('break_2')) +// DexExpectWatchValue('tmp[0]', 6, on_line=ref('break_2')) +// DexExpectWatchValue('tmp[1]', 8, on_line=ref('break_2')) +// DexExpectWatchValue('tmp[2]', 10, on_line=ref('break_2')) +// DexExpectWatchValue('tmp[3]', 12, on_line=ref('break_2')) +// DexLimitSteps('i', 3, on_line=ref('break_3')) +// DexExpectWatchValue('tmp[0]', 63, on_line=ref('break_3')) +// DexExpectWatchValue('tmp[1]', 94, on_line=ref('break_3')) +// DexExpectWatchValue('tmp[2]', 95, on_line=ref('break_3')) +// DexExpectWatchValue('tmp[3]', 120, on_line=ref('break_3')) +// DexLimitSteps('i', 3, on_line=ref('break_5')) +// DexExpectWatchValue('tmp[0]', 15, on_line=ref('break_5')) template __attribute__((optnone)) @@ -93,15 +93,15 @@ result[i] = InVec[i]; // DexLabel('break_6') return result; // DexLabel('break_7') } -// DexLimitSteps('i', '3', from_line='break_6', to_line='break_7') -// DexExpectWatchValue('InVec[0]', 15, from_line='break_6', to_line='break_7') -// DexExpectWatchValue('InVec[1]', 190, from_line='break_6', to_line='break_7') -// DexExpectWatchValue('InVec[2]', 191, from_line='break_6', to_line='break_7') -// DexExpectWatchValue('InVec[3]', 248, from_line='break_6', to_line='break_7') -// DexExpectWatchValue('result[0]', 15, from_line='break_6', to_line='break_7') -// DexExpectWatchValue('result[1]', 190, from_line='break_6', to_line='break_7') -// DexExpectWatchValue('result[2]', 191, from_line='break_6', to_line='break_7') -// DexExpectWatchValue('result[3]', 248, on_line='break_7') +// DexLimitSteps('i', '3', from_line=ref('break_6'), to_line=ref('break_7')) +// DexExpectWatchValue('InVec[0]', 15, from_line=ref('break_6'), to_line=ref('break_7')) +// DexExpectWatchValue('InVec[1]', 190, from_line=ref('break_6'), to_line=ref('break_7')) +// DexExpectWatchValue('InVec[2]', 191, from_line=ref('break_6'), to_line=ref('break_7')) +// DexExpectWatchValue('InVec[3]', 248, from_line=ref('break_6'), to_line=ref('break_7')) +// DexExpectWatchValue('result[0]', 15, from_line=ref('break_6'), to_line=ref('break_7')) +// DexExpectWatchValue('result[1]', 190, from_line=ref('break_6'), to_line=ref('break_7')) +// DexExpectWatchValue('result[2]', 191, from_line=ref('break_6'), to_line=ref('break_7')) +// DexExpectWatchValue('result[3]', 248, on_line=ref('break_7')) template __attribute__((optnone)) @@ -110,18 +110,18 @@ x[i] = (x[i] > y[i])? x[i] : y[i] + TypeTraits::MysteryNumber; // DexLabel('break_11') return x; // DexLabel('break_12') } -// DexLimitSteps('1', '1', from_line='break_11', to_line='break_12') +// DexLimitSteps('1', '1', from_line=ref('break_11'), to_line=ref('break_12')) //// FIXME: lldb won't print this but gdb unexpectedly says it's optimized out, even at O0. -// \DexExpectWatchValue('TypeTraits::MysteryNumber', 3, on_line='break_11') -// DexExpectWatchValue('i', 0, 1, 2, 3, on_line='break_11') -// DexExpectWatchValue('x[0]', 1, 8, from_line='break_11', to_line='break_12') -// DexExpectWatchValue('x[1]', 2, 9, from_line='break_11', to_line='break_12') -// DexExpectWatchValue('x[2]', 3, 10, from_line='break_11', to_line='break_12') -// DexExpectWatchValue('x[3]', 4, 11, from_line='break_11', to_line='break_12') -// DexExpectWatchValue('y[0]', 5, from_line='break_11', to_line='break_12') -// DexExpectWatchValue('y[1]', 6, from_line='break_11', to_line='break_12') -// DexExpectWatchValue('y[2]', 7, from_line='break_11', to_line='break_12') -// DexExpectWatchValue('y[3]', 8, from_line='break_11', to_line='break_12') +// \DexExpectWatchValue('TypeTraits::MysteryNumber', 3, on_line=ref('break_11')) +// DexExpectWatchValue('i', 0, 1, 2, 3, on_line=ref('break_11')) +// DexExpectWatchValue('x[0]', 1, 8, from_line=ref('break_11'), to_line=ref('break_12')) +// DexExpectWatchValue('x[1]', 2, 9, from_line=ref('break_11'), to_line=ref('break_12')) +// DexExpectWatchValue('x[2]', 3, 10, from_line=ref('break_11'), to_line=ref('break_12')) +// DexExpectWatchValue('x[3]', 4, 11, from_line=ref('break_11'), to_line=ref('break_12')) +// DexExpectWatchValue('y[0]', 5, from_line=ref('break_11'), to_line=ref('break_12')) +// DexExpectWatchValue('y[1]', 6, from_line=ref('break_11'), to_line=ref('break_12')) +// DexExpectWatchValue('y[2]', 7, from_line=ref('break_11'), to_line=ref('break_12')) +// DexExpectWatchValue('y[3]', 8, from_line=ref('break_11'), to_line=ref('break_12')) int main() { int4 a = (int4){1,2,3,4}; diff --git a/debuginfo-tests/dexter-tests/realigned-frame.cpp b/debuginfo-tests/dexter-tests/realigned-frame.cpp --- a/debuginfo-tests/dexter-tests/realigned-frame.cpp +++ b/debuginfo-tests/dexter-tests/realigned-frame.cpp @@ -27,7 +27,7 @@ } /* DexExpectProgramState({'frames':[ - {'function': 'Foo::bar', 'location' : {'lineno' : 'in_bar'} }, + {'function': 'Foo::bar', 'location' : {'lineno' : ref('in_bar')} }, {'function': 'Foo::foo', 'watches' : { 'a' : '1', diff --git a/debuginfo-tests/dexter-tests/stack-var.c b/debuginfo-tests/dexter-tests/stack-var.c --- a/debuginfo-tests/dexter-tests/stack-var.c +++ b/debuginfo-tests/dexter-tests/stack-var.c @@ -12,6 +12,6 @@ return test; // DexLabel('after_bar') } -// DexExpectWatchValue('test', '23', on_line='before_bar') -// DexExpectWatchValue('test', '23', on_line='after_bar') +// DexExpectWatchValue('test', '23', on_line=ref('before_bar')) +// DexExpectWatchValue('test', '23', on_line=ref('after_bar')) diff --git a/debuginfo-tests/dexter-tests/vla.c b/debuginfo-tests/dexter-tests/vla.c --- a/debuginfo-tests/dexter-tests/vla.c +++ b/debuginfo-tests/dexter-tests/vla.c @@ -18,6 +18,6 @@ return 0; } -// DexExpectWatchValue('vla[0]', '23', on_line='end_init') -// DexExpectWatchValue('vla[1]', '22', on_line='end_init') +// DexExpectWatchValue('vla[0]', '23', on_line=ref('end_init')) +// DexExpectWatchValue('vla[1]', '22', on_line=ref('end_init')) diff --git a/debuginfo-tests/dexter/feature_tests/commands/penalty/expect_program_state.cpp b/debuginfo-tests/dexter/feature_tests/commands/penalty/expect_program_state.cpp --- a/debuginfo-tests/dexter/feature_tests/commands/penalty/expect_program_state.cpp +++ b/debuginfo-tests/dexter/feature_tests/commands/penalty/expect_program_state.cpp @@ -24,7 +24,7 @@ 'frames': [ { 'location': { - 'lineno': 'check' + 'lineno': ref('check') }, 'watches': { 'lhs': '0', 'rhs': '0' diff --git a/debuginfo-tests/dexter/feature_tests/commands/penalty/expect_watch_type.cpp b/debuginfo-tests/dexter/feature_tests/commands/penalty/expect_watch_type.cpp --- a/debuginfo-tests/dexter/feature_tests/commands/penalty/expect_watch_type.cpp +++ b/debuginfo-tests/dexter/feature_tests/commands/penalty/expect_watch_type.cpp @@ -45,13 +45,13 @@ } -// DexExpectWatchType('m_member', 'int', 'double', from_line='gv_start', to_line='gv_end') +// DexExpectWatchType('m_member', 'int', 'double', from_line=ref('gv_start'), to_line=ref('gv_end')) // THIS COMMAND should create a penalty for a missing type 'const double' and unexpected type 'const double &' -// DexExpectWatchType('to_double', 'const double', 'const int &', from_line='sd_start', to_line='sd_end') +// DexExpectWatchType('to_double', 'const double', 'const int &', from_line=ref('sd_start'), to_line=ref('sd_end')) -// DexExpectWatchType('myInt', 'Doubled', from_line='main_start', to_line='main_end') -// DexExpectWatchType('myDouble', 'Doubled', from_line='main_start', to_line='main_end') -// DexExpectWatchType('staticallyDoubledInt', 'int', from_line='main_start', to_line='main_end') -// DexExpectWatchType('staticallyDoubledDouble', 'double', from_line='main_start', to_line='main_end') +// DexExpectWatchType('myInt', 'Doubled', from_line=ref('main_start'), to_line=ref('main_end')) +// DexExpectWatchType('myDouble', 'Doubled', from_line=ref('main_start'), to_line=ref('main_end')) +// DexExpectWatchType('staticallyDoubledInt', 'int', from_line=ref('main_start'), to_line=ref('main_end')) +// DexExpectWatchType('staticallyDoubledDouble', 'double', from_line=ref('main_start'), to_line=ref('main_end')) diff --git a/debuginfo-tests/dexter/feature_tests/commands/penalty/expect_watch_value.cpp b/debuginfo-tests/dexter/feature_tests/commands/penalty/expect_watch_value.cpp --- a/debuginfo-tests/dexter/feature_tests/commands/penalty/expect_watch_value.cpp +++ b/debuginfo-tests/dexter/feature_tests/commands/penalty/expect_watch_value.cpp @@ -15,6 +15,6 @@ return 0; // DexLabel('ret') } -// DexExpectWatchValue('i', '0', '1', '2', on_line='loop') -// DexExpectWatchValue('i', '3', on_line='ret') +// DexExpectWatchValue('i', '0', '1', '2', on_line=ref('loop')) +// DexExpectWatchValue('i', '3', on_line=ref('ret')) // ---------------------^ out of scope diff --git a/debuginfo-tests/dexter/feature_tests/commands/perfect/expect_program_state.cpp b/debuginfo-tests/dexter/feature_tests/commands/perfect/expect_program_state.cpp --- a/debuginfo-tests/dexter/feature_tests/commands/perfect/expect_program_state.cpp +++ b/debuginfo-tests/dexter/feature_tests/commands/perfect/expect_program_state.cpp @@ -25,7 +25,7 @@ 'frames': [ { 'location': { - 'lineno': 'check' + 'lineno': ref('check') }, 'watches': { 'lhs': '37', 'rhs': '0' diff --git a/debuginfo-tests/dexter/feature_tests/commands/perfect/expect_watch_type.cpp b/debuginfo-tests/dexter/feature_tests/commands/perfect/expect_watch_type.cpp --- a/debuginfo-tests/dexter/feature_tests/commands/perfect/expect_watch_type.cpp +++ b/debuginfo-tests/dexter/feature_tests/commands/perfect/expect_watch_type.cpp @@ -43,12 +43,12 @@ + staticallyDoubledDouble); // DexLabel('main_end') } -// DexExpectWatchType('m_member', 'int', 'double', from_line='gv_start', to_line='gv_end') +// DexExpectWatchType('m_member', 'int', 'double', from_line=ref('gv_start'), to_line=ref('gv_end')) -// DexExpectWatchType('to_double', 'const int &', 'const double &', from_line='sd_start', to_line='sd_end') +// DexExpectWatchType('to_double', 'const int &', 'const double &', from_line=ref('sd_start'), to_line=ref('sd_end')) -// DexExpectWatchType('myInt', 'Doubled', from_line='main_start', to_line='main_end') -// DexExpectWatchType('myDouble', 'Doubled', from_line='main_start', to_line='main_end') -// DexExpectWatchType('staticallyDoubledInt', 'int', from_line='main_start', to_line='main_end') -// DexExpectWatchType('staticallyDoubledDouble', 'double', from_line='main_start', to_line='main_end') +// DexExpectWatchType('myInt', 'Doubled', from_line=ref('main_start'), to_line=ref('main_end')) +// DexExpectWatchType('myDouble', 'Doubled', from_line=ref('main_start'), to_line=ref('main_end')) +// DexExpectWatchType('staticallyDoubledInt', 'int', from_line=ref('main_start'), to_line=ref('main_end')) +// DexExpectWatchType('staticallyDoubledDouble', 'double', from_line=ref('main_start'), to_line=ref('main_end')) diff --git a/debuginfo-tests/dexter/feature_tests/commands/perfect/expect_watch_value.cpp b/debuginfo-tests/dexter/feature_tests/commands/perfect/expect_watch_value.cpp --- a/debuginfo-tests/dexter/feature_tests/commands/perfect/expect_watch_value.cpp +++ b/debuginfo-tests/dexter/feature_tests/commands/perfect/expect_watch_value.cpp @@ -22,16 +22,16 @@ } /* -DexExpectWatchValue('n', '8', on_line='entry') +DexExpectWatchValue('n', '8', on_line=ref('entry')) DexExpectWatchValue('i', '1', '2', '3', '4', '5', '6', '7', '8', - on_line='loop') + on_line=ref('loop')) DexExpectWatchValue('fac', '1', '2', '6', '24', '120', '720', '5040', - on_line='loop') + on_line=ref('loop')) -DexExpectWatchValue('n', '8', on_line='loop') -DexExpectWatchValue('fac', '40320', on_line='ret') -DexExpectWatchValue('n', '8', on_line='ret') +DexExpectWatchValue('n', '8', on_line=ref('loop')) +DexExpectWatchValue('fac', '40320', on_line=ref('ret')) +DexExpectWatchValue('n', '8', on_line=ref('ret')) */ diff --git a/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_check_json_step_count.cpp b/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_check_json_step_count.cpp --- a/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_check_json_step_count.cpp +++ b/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_check_json_step_count.cpp @@ -16,5 +16,5 @@ } } -// DexExpectWatchValue('index', 2, 7, 9, on_line='check') -// DexLimitSteps('ix', 2, 7, 9, on_line='check') +// DexExpectWatchValue('index', 2, 7, 9, on_line=ref('check')) +// DexLimitSteps('ix', 2, 7, 9, on_line=ref('check')) diff --git a/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_expect_loop.cpp b/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_expect_loop.cpp --- a/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_expect_loop.cpp +++ b/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_expect_loop.cpp @@ -16,5 +16,5 @@ return sum; } -// DexLimitSteps('ix', 0, 3, from_line='start', to_line='end') -// DexExpectWatchValue('ix', 0, 3, from_line='start', to_line='end') +// DexLimitSteps('ix', 0, 3, from_line=ref('start'), to_line=ref('end')) +// DexExpectWatchValue('ix', 0, 3, from_line=ref('start'), to_line=ref('end')) diff --git a/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_expect_value.cpp b/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_expect_value.cpp --- a/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_expect_value.cpp +++ b/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_expect_value.cpp @@ -14,5 +14,5 @@ return 0; // DexLabel('long_range') } -// DexLimitSteps('i', '0', from_line='from', to_line='long_range') -// DexExpectWatchValue('i', 0, 1, 2, 3, from_line='from', to_line='long_range') +// DexLimitSteps('i', '0', from_line=ref('from'), to_line=ref('long_range')) +// DexExpectWatchValue('i', 0, 1, 2, 3, from_line=ref('from'), to_line=ref('long_range')) diff --git a/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_line_mismatch.cpp b/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_line_mismatch.cpp --- a/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_line_mismatch.cpp +++ b/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_line_mismatch.cpp @@ -21,5 +21,5 @@ return ret; // DexLabel('to') } -// DexLimitSteps('1', '1', from_line='from', to_line='to') -// DexExpectWatchValue('i', 0, 1, 2, from_line='from', to_line='to') +// DexLimitSteps('1', '1', from_line=ref('from'), to_line=ref('to')) +// DexExpectWatchValue('i', 0, 1, 2, from_line=ref('from'), to_line=ref('to')) diff --git a/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_overlapping_ranges.cpp b/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_overlapping_ranges.cpp --- a/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_overlapping_ranges.cpp +++ b/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_overlapping_ranges.cpp @@ -27,10 +27,10 @@ return val1 + val2; } -// DexExpectWatchValue('ix', 0, 2, 5, from_line='from', to_line='to') -// DexExpectWatchValue('val1', 0, from_line='val1_check', to_line='val1_check_to') -// DexExpectWatchValue('val2', 2, from_line='val2_check', to_line='val2_check_to') +// DexExpectWatchValue('ix', 0, 2, 5, from_line=ref('from'), to_line=ref('to')) +// DexExpectWatchValue('val1', 0, from_line=ref('val1_check'), to_line=ref('val1_check_to')) +// DexExpectWatchValue('val2', 2, from_line=ref('val2_check'), to_line=ref('val2_check_to')) -// DexLimitSteps('ix', 5, from_line='from', to_line='to') -// DexLimitSteps('val1', 0, from_line='val1_check', to_line='val1_check_to') -// DexLimitSteps('val2', 2, from_line='val2_check', to_line='val2_check_to') +// DexLimitSteps('ix', 5, from_line=ref('from'), to_line=ref('to')) +// DexLimitSteps('val1', 0, from_line=ref('val1_check'), to_line=ref('val1_check_to')) +// DexLimitSteps('val2', 2, from_line=ref('val2_check'), to_line=ref('val2_check_to')) diff --git a/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_same_line_conditional.cpp b/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_same_line_conditional.cpp --- a/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_same_line_conditional.cpp +++ b/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/limit_steps_same_line_conditional.cpp @@ -20,7 +20,7 @@ return val1 + placeholder; } -// DexExpectWatchValue('val1', 0, 1, 3, from_line='from', to_line='extended_to') +// DexExpectWatchValue('val1', 0, 1, 3, from_line=ref('from'), to_line=ref('extended_to')) -// DexLimitSteps('ix', 0, from_line='from', to_line='to') -// DexLimitSteps('ix', 1, from_line='from', to_line='extended_to') +// DexLimitSteps('ix', 0, from_line=ref('from'), to_line=ref('to')) +// DexLimitSteps('ix', 1, from_line=ref('from'), to_line=ref('extended_to')) diff --git a/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/unconditional.cpp b/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/unconditional.cpp --- a/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/unconditional.cpp +++ b/debuginfo-tests/dexter/feature_tests/commands/perfect/limit_steps/unconditional.cpp @@ -17,7 +17,7 @@ return test; // test = 4 } -// DexLimitSteps(from_line='from', to_line='to') +// DexLimitSteps(from_line=ref('from'), to_line=ref('to')) //// Unconditionally limit dexter's view of the program from line 'from' to //// 'to'. Check for test=0, 1, 2 so that the test will fail if dexter sees //// test=0 or test=4. diff --git a/debuginfo-tests/dexter/feature_tests/subtools/test/label_another_line.cpp b/debuginfo-tests/dexter/feature_tests/subtools/test/label_another_line.cpp --- a/debuginfo-tests/dexter/feature_tests/subtools/test/label_another_line.cpp +++ b/debuginfo-tests/dexter/feature_tests/subtools/test/label_another_line.cpp @@ -14,4 +14,4 @@ } // DexLabel('test', on_line=13) -// DexExpectWatchValue('result', '0', on_line='test') +// DexExpectWatchValue('result', '0', on_line=ref('test')) diff --git a/debuginfo-tests/dexter/feature_tests/subtools/test/label_another_line.cpp.rej b/debuginfo-tests/dexter/feature_tests/subtools/test/label_another_line.cpp.rej new file mode 100644 --- /dev/null +++ b/debuginfo-tests/dexter/feature_tests/subtools/test/label_another_line.cpp.rej @@ -0,0 +1,7 @@ +diff a/debuginfo-tests/dexter/feature_tests/subtools/test/label_another_line.cpp b/debuginfo-tests/dexter/feature_tests/subtools/test/label_another_line.cpp (rejected hunks) +@@ -11,4 +11,4 @@ + } + + // DexLabel('test', on_line=10) +-// DexExpectWatchValue('result', '0', on_line=ref('test')) ++// DexExpectWatchValue('result', '0', on_line=ref('test')) diff --git a/debuginfo-tests/dexter/feature_tests/subtools/test/source-root-dir.cpp b/debuginfo-tests/dexter/feature_tests/subtools/test/source-root-dir.cpp --- a/debuginfo-tests/dexter/feature_tests/subtools/test/source-root-dir.cpp +++ b/debuginfo-tests/dexter/feature_tests/subtools/test/source-root-dir.cpp @@ -12,4 +12,4 @@ printf("hello world: %d\n", x); // DexLabel('check') } -// DexExpectWatchValue('x', 42, on_line='check') +// DexExpectWatchValue('x', 42, on_line=ref('check')) diff --git a/debuginfo-tests/dexter/feature_tests/subtools/view.cpp b/debuginfo-tests/dexter/feature_tests/subtools/view.cpp --- a/debuginfo-tests/dexter/feature_tests/subtools/view.cpp +++ b/debuginfo-tests/dexter/feature_tests/subtools/view.cpp @@ -15,4 +15,4 @@ int a = 0; return 0; //DexLabel('ret') } -// DexExpectWatchValue('a', '0', on_line='ret') +// DexExpectWatchValue('a', '0', on_line=ref('ret'))