[PATCH] D97726: [sanitizers] [windows] Use InternalMmapVector instead of silencing -Wframe-larger-than

Russell Gallop via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 10 01:01:08 PST 2021


russell.gallop added a comment.

With an additional change from sizeof(buf) to buf.size() this fixes the check-asan and check-ubsan tests.

Note that there are 5 check-asan tests which fail for me with and without this patch:

  AddressSanitizer-x86_64-windows :: TestCases/Windows/delay_dbghelp.cpp
  AddressSanitizer-x86_64-windows :: TestCases/Windows/dll_host.cpp
  AddressSanitizer-x86_64-windows :: TestCases/Windows/interface_symbols_windows.cpp
  AddressSanitizer-x86_64-windows :: TestCases/Windows/iostream_sbo.cpp
  AddressSanitizer-x86_64-windows :: TestCases/Windows/symbols_path.cpp

I don't have time to dig into these at the moment.



================
Comment at: compiler-rt/lib/sanitizer_common/sanitizer_win.cpp:599
+  if (!ReadFromFile(fd, &buf[0], buf.size(), &bytes_read) ||
       bytes_read != sizeof(buf))
     return 0;
----------------
I think that this line needs changing from sizeof(buf) to buf.size() as well.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D97726/new/

https://reviews.llvm.org/D97726



More information about the llvm-commits mailing list