eteran / edb-debugger

edb is a cross-platform AArch32/x86/x86-64 debugger.
GNU General Public License v2.0
2.7k stars 326 forks source link

ARM regression fixes #714

Closed 10110111 closed 5 years ago

10110111 commented 5 years ago

This fixes building of EDB on ARM32 for me. I don't know whether anything was broken for runtime, but at least compilation is fixed now.

Fixes most of the problems which are discussed in #713 (except the one with Capstone, which is the user-side problem, not EDB).

eteran commented 5 years ago

So that static_assert that you made an assert... I don't see how it won't trigger at runtime, both operands are not dependant on runtime values, so it's either true or it isn't :-/.

I suspect that this will compile on arm, but if that code path is ever executed, it's probably a guaranteed assert.

10110111 commented 5 years ago

I suspect that this will compile on arm, but if that code path is ever executed, it's probably a guaranteed assert.

The static assertion won't compile (because long double is 64-bit on ARM). The function is useless on ARM, but since we aren't trying to optimize for size, I didn't try to complicate the code to avoid this instantiation of the template.

eteran commented 5 years ago

Gotcha, so it'll compile, but won't ever be run at runtime then. Makes sense.