Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to compile at Mariner 3.0 + gcc 13 + Address Sanitizer #933

Open
doctorlai-msrc opened this issue Aug 30, 2024 · 0 comments
Open

Comments

@doctorlai-msrc
Copy link

doctorlai-msrc commented Aug 30, 2024

OS: mcr.microsoft.com/azurelinux/base/core:3.0
gcc: 13.2.0
g++: 13.2.0
Built with Address Sanitizer.

error: '__atomic_load_8' writing 8 bytes into a region of size 0 overflows the destination [-Werror=stringop-overflow=]

In file included from /janus/3p/mimalloc/include/mimalloc/internal.h:17,
                 from /janus/3p/mimalloc/src/heap.c:9:
In function 'mi_heap_page_is_valid',
    inlined from 'mi_heap_page_collect' at /janus/3p/mimalloc/src/heap.c:95:3:
/janus/3p/mimalloc/src/heap.c:62:22: error: '__atomic_load_8' writing 8 bytes into a region of size 0 overflows the destination [-Werror=stringop-overflow=]
   62 |   mi_assert_internal(segment->thread_id == heap->thread_id);
      |                      ^~~~~~~
/janus/3p/mimalloc/include/mimalloc/types.h:509:31: note: in definition of macro 'mi_assert'
  509 | #define mi_assert(expr)     ((expr) ? (void)0 : _mi_assert_fail(#expr,__FILE__,__LINE__,__func__))
      |                               ^~~~
/janus/3p/mimalloc/src/heap.c:62:3: note: in expansion of macro 'mi_assert_internal'
   62 |   mi_assert_internal(segment->thread_id == heap->thread_id);
      |   ^~~~~~~~~~~~~~~~~~
In function 'mi_heap_page_collect':
cc1: note: destination object is likely at address zero
In function 'mi_heap_page_is_valid',
    inlined from 'mi_heap_page_collect' at /janus/3p/mimalloc/src/heap.c:95:3:
/janus/3p/mimalloc/src/heap.c:62:22: error: '__atomic_load_8' writing 8 bytes into a region of size 0 overflows the destination [-Werror=stringop-overflow=]
   62 |   mi_assert_internal(segment->thread_id == heap->thread_id);
      |                      ^~~~~~~
/janus/3p/mimalloc/include/mimalloc/types.h:509:31: note: in definition of macro 'mi_assert'
  509 | #define mi_assert(expr)     ((expr) ? (void)0 : _mi_assert_fail(#expr,__FILE__,__LINE__,__func__))
      |                               ^~~~
/janus/3p/mimalloc/src/heap.c:62:3: note: in expansion of macro 'mi_assert_internal'
   62 |   mi_assert_internal(segment->thread_id == heap->thread_id);
      |   ^~~~~~~~~~~~~~~~~~
In function 'mi_heap_page_collect':
cc1: note: destination object is likely at address zero
[ 17%] Built target janus_logger
[ 18%] Building C object 3p/mimalloc/CMakeFiles/mimalloc.dir/src/prim/prim.c.o
In file included from /janus/3p/ebpf-verifier/src/btf_parser.cpp:8:
/janus/3p/ebpf-verifier/src/btf.h:119: warning: ignoring '#pragma warning ' [-Wunknown-pragmas]
  119 | #pragma warning(push)
      | 
/janus/3p/ebpf-verifier/src/btf.h:120: warning: ignoring '#pragma warning ' [-Wunknown-pragmas]
  120 | #pragma warning(disable : 4200) // nonstandard extension used: zero-sized array in struct/union
      | 
/janus/3p/ebpf-verifier/src/btf.h:127: warning: ignoring '#pragma warning ' [-Wunknown-pragmas]
  127 | #pragma warning(pop)
      | 
[ 19%] Building CXX object 3p/ebpf-verifier/CMakeFiles/ebpfverifier.dir/src/crab/interval.cpp.o
[ 19%] Building CXX object 3p/ebpf-verifier/CMakeFiles/ebpfverifier.dir/src/crab/split_dbm.cpp.o
In file included from /janus/3p/mimalloc/include/mimalloc/internal.h:17,
                 from /janus/3p/mimalloc/src/heap.c:9:
In function 'mi_heap_page_is_valid',
    inlined from 'mi_heap_page_collect' at /janus/3p/mimalloc/src/heap.c:95:3:
/janus/3p/mimalloc/src/heap.c:62:22: error: '__atomic_load_8' writing 8 bytes into a region of size 0 overflows the destination [-Werror=stringop-overflow=]
   62 |   mi_assert_internal(segment->thread_id == heap->thread_id);
      |                      ^~~~~~~
/janus/3p/mimalloc/include/mimalloc/types.h:509:31: note: in definition of macro 'mi_assert'
  509 | #define mi_assert(expr)     ((expr) ? (void)0 : _mi_assert_fail(#expr,__FILE__,__LINE__,__func__))
      |                               ^~~~
/janus/3p/mimalloc/src/heap.c:62:3: note: in expansion of macro 'mi_assert_internal'
   62 |   mi_assert_internal(segment->thread_id == heap->thread_id);
      |   ^~~~~~~~~~~~~~~~~~
In function 'mi_heap_page_collect':
cc1: note: destination object is likely at address zero
In function 'mi_heap_page_is_valid',
    inlined from 'mi_heap_page_collect' at /janus/3p/mimalloc/src/heap.c:95:3:
/janus/3p/mimalloc/src/heap.c:62:22: error: '__atomic_load_8' writing 8 bytes into a region of size 0 overflows the destination [-Werror=stringop-overflow=]
   62 |   mi_assert_internal(segment->thread_id == heap->thread_id);
      |                      ^~~~~~~
/janus/3p/mimalloc/include/mimalloc/types.h:509:31: note: in definition of macro 'mi_assert'
  509 | #define mi_assert(expr)     ((expr) ? (void)0 : _mi_assert_fail(#expr,__FILE__,__LINE__,__func__))
      |                               ^~~~
/janus/3p/mimalloc/src/heap.c:62:3: note: in expansion of macro 'mi_assert_internal'
   62 |   mi_assert_internal(segment->thread_id == heap->thread_id);
      |   ^~~~~~~~~~~~~~~~~~
In function 'mi_heap_page_collect':
cc1: note: destination object is likely at address zero
Detecting operating system.......[ 19%] Building CXX object 3p/ebpf-verifier/CMakeFiles/ebpfverifier.dir/src/crab/thresholds.cpp.o
[ 20%] Building CXX object 3p/ebpf-verifier/CMakeFiles/ebpfverifier.dir/src/crab/var_factory.cpp.o
[ 20%] Building C object src/lcm/CMakeFiles/janus_lcm.dir/janus_lcm_ipc.c.o
[ 20%] Building CXX object 3p/ebpf-verifier/CMakeFiles/ebpfverifier.dir/src/crab/wto.cpp.o
egrep: warning: egrep is obsolescent; using grep -E
[ 20%] Building CXX object 3p/ebpf-verifier/CMakeFiles/ebpfverifier.dir/src/crab_utils/debug.cpp.o
success [linux]
Detecting machine architecture...success [x86_64]
Finding dirname command..........[ 20%] Building CXX object 3p/ebpf-verifier/CMakeFiles/ebpfverifier.dir/src/crab_utils/stats.cpp.o
success [/usr/bin/dirname]
@doctorlai-msrc doctorlai-msrc changed the title Failed to compile at Mariner 3.0 + gcc 13 Failed to compile at Mariner 3.0 + gcc 13 + Address Sanitizer Aug 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant