Closed zhangbaozhe closed 1 year ago
I've been compiling your code in C++17 and added -fsanitize=address,undefined in debug mode to check some errors.
-fsanitize=address,undefined
The executable compiled in debug mode complained of a runtime error (store to misaligned address for type 'double', which requires 8 byte alignment) around https://github.com/ZJU-FAST-Lab/GCOPTER/blob/63c5861735046079c925c6937475cb1033a51691/gcopter/include/gcopter/firi.hpp#L95 I've digged around the code, and found that https://github.com/ZJU-FAST-Lab/GCOPTER/blob/63c5861735046079c925c6937475cb1033a51691/gcopter/include/gcopter/firi.hpp#L187 this line has some alignment issue where int should be replaced with some 64-bit type such as unsigned long aka int64_t.
int
unsigned long
int64_t
Thanks!
I've been compiling your code in C++17 and added
-fsanitize=address,undefined
in debug mode to check some errors.The executable compiled in debug mode complained of a runtime error (store to misaligned address for type 'double', which requires 8 byte alignment) around https://github.com/ZJU-FAST-Lab/GCOPTER/blob/63c5861735046079c925c6937475cb1033a51691/gcopter/include/gcopter/firi.hpp#L95 I've digged around the code, and found that https://github.com/ZJU-FAST-Lab/GCOPTER/blob/63c5861735046079c925c6937475cb1033a51691/gcopter/include/gcopter/firi.hpp#L187 this line has some alignment issue where
int
should be replaced with some 64-bit type such asunsigned long
akaint64_t
.