static uintptr_t eval_binary_operation(simgrid::dwarf::ExpressionContext const& state, uint8_t op, uintptr_t a,
uintptr_t b)
{
static uintptr_t eval_binary_operation(simgrid::dwarf::ExpressionContext const& state, uint8_t op, uintptr_t a,
uintptr_t b)
{
- simgrid::dwarf::execute(ops, 3, state, stack);
+ simgrid::dwarf::execute(ops.data(), 3, state, stack);
} catch (const simgrid::dwarf::evaluation_error&) {
fprintf(stderr,"Expression evaluation error");
}
} catch (const simgrid::dwarf::evaluation_error&) {
fprintf(stderr,"Expression evaluation error");
}
- simgrid::dwarf::execute(ops, 1, state, stack);
+ simgrid::dwarf::execute(ops.data(), 1, state, stack);
fprintf(stderr, "Exception expected");
ops[0].atom = DW_OP_lit21;
fprintf(stderr, "Exception expected");
ops[0].atom = DW_OP_lit21;
- simgrid::dwarf::execute(ops, 1, state, stack);
+ simgrid::dwarf::execute(ops.data(), 1, state, stack);
assert(stack.size() == 1);
assert(stack.top() == 21);
ops[0].atom = DW_OP_const8u;
ops[0].number = a;
assert(stack.size() == 1);
assert(stack.top() == 21);
ops[0].atom = DW_OP_const8u;
ops[0].number = a;
- simgrid::dwarf::execute(ops, 1, state, stack);
+ simgrid::dwarf::execute(ops.data(), 1, state, stack);
assert(stack.size() == 2);
assert(stack.top() == a);
ops[0].atom = DW_OP_drop;
ops[1].atom = DW_OP_drop;
assert(stack.size() == 2);
assert(stack.top() == a);
ops[0].atom = DW_OP_drop;
ops[1].atom = DW_OP_drop;
- simgrid::dwarf::execute(ops, 2, state, stack);
+ simgrid::dwarf::execute(ops.data(), 2, state, stack);
- simgrid::dwarf::execute(ops, 2, state, stack);
+ simgrid::dwarf::execute(ops.data(), 2, state, stack);
- simgrid::dwarf::execute(ops, 3, state, stack);
+ simgrid::dwarf::execute(ops.data(), 3, state, stack);
- simgrid::dwarf::execute(ops, 3, state, stack);
+ simgrid::dwarf::execute(ops.data(), 3, state, stack);
assert(stack.size() == 3);
assert(stack.top() == a);
assert(stack.top(1) == b);
assert(stack.size() == 3);
assert(stack.top() == a);
assert(stack.top(1) == b);
- simgrid::dwarf::execute(ops, 3, state, stack);
+ simgrid::dwarf::execute(ops.data(), 3, state, stack);
assert(stack.size() == 2);
assert(stack.top() == a);
assert(stack.top(1) == b);
assert(stack.size() == 2);
assert(stack.top() == a);
assert(stack.top(1) == b);
ops[0].atom = DW_OP_const8u;
ops[0].number = (uintptr_t)&foo;
ops[1].atom = DW_OP_deref;
simgrid::dwarf::ExpressionStack stack;
ops[0].atom = DW_OP_const8u;
ops[0].number = (uintptr_t)&foo;
ops[1].atom = DW_OP_deref;
simgrid::dwarf::ExpressionStack stack;
- simgrid::dwarf::execute(ops, 2, state, stack);
+ simgrid::dwarf::execute(ops.data(), 2, state, stack);
assert(stack.size() == 1);
assert(stack.top() == foo);
} catch (const simgrid::dwarf::evaluation_error&) {
assert(stack.size() == 1);
assert(stack.top() == foo);
} catch (const simgrid::dwarf::evaluation_error&) {