[Dwarf-Discuss] PROPOSAL: Constant expressions in location lists
Mon Jan 7 02:23:54 GMT 2008
On Jan 6, 2008, at 5:26 PM, Jim Blandy wrote:
> At first blush, this might seem like a horrible bloat of the DWARF
> spec: would the spec have to describe (say) C's integral type
> promotion rules for binary operators, the proper handling of 0 when it
> appears as the second or third operand of a ?: expression, and so on?
Why would you want to encode it at the source level? You just need
the ability for the compiler to express how to compute it, which
doesn't require source-level rules. For example, instead of
expressing all the semantics of C casts, you could have explicit sign
extend, truncate, zero extend, etc operations, and have the compiler
emit those instead.
In fact, this would be a better parity match with most compiler
More information about the Dwarf-discuss