[all-commits] [llvm/llvm-project] de7105: [ASAN] Initial support memory checks on scalable v...

Philip Reames via All-commits all-commits at lists.llvm.org
Wed Mar 15 07:59:58 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: de71056a7dbce33186687153af267e0503bbacdc
      https://github.com/llvm/llvm-project/commit/de71056a7dbce33186687153af267e0503bbacdc
  Author: Philip Reames <preames at rivosinc.com>
  Date:   2023-03-15 (Wed, 15 Mar 2023)

  Changed paths:
    M llvm/lib/Transforms/Instrumentation/AddressSanitizer.cpp
    M llvm/test/Instrumentation/AddressSanitizer/vector-load-store.ll

  Log Message:
  -----------
  [ASAN] Initial support memory checks on scalable vector typed allocas

This patch adjusts the memory instrumentation to account for scalable vector types in allocas. Note that we don't allow scalable vector globals, so we don't need to update that codepath.

A couple points.

First, this simply disables the optimization for scalable allocas. We can revisit this in the future, but it requires a bit of plumbing to get scalable object sizes through the visitor to be useful.

Second, I am simply disabling stack poisoning for scalable vector allocas. This is mostly for staging the change as I can't write a working test for memory instrumentation without doing so. I don't think it's unreasonable to do on it's own basis as without the bailout, we crash the compiler.

Differential Revision: https://reviews.llvm.org/D145259




More information about the All-commits mailing list