[PATCH] D20547: [safestack] Sink unsafe address computation to each use.

Evgeniy Stepanov via llvm-commits llvm-commits at lists.llvm.org
Mon May 23 17:22:23 PDT 2016


eugenis created this revision.
eugenis added a reviewer: pcc.
eugenis added a subscriber: llvm-commits.
eugenis set the repository for this revision to rL LLVM.

This is a fix for PR27844.
When replacing uses of unsafe allocas, emit the new location immediately after each use. 
Without this, the pointer stays live from the function entry to the last use, while it's usually cheaper to recalculate.

Repository:
  rL LLVM

http://reviews.llvm.org/D20547

Files:
  lib/CodeGen/SafeStack.cpp
  test/Transforms/SafeStack/array-aligned.ll
  test/Transforms/SafeStack/array.ll
  test/Transforms/SafeStack/sink-to-use.ll
  test/Transforms/SafeStack/struct.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D20547.58177.patch
Type: text/x-patch
Size: 5948 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160524/c2e9066c/attachment.bin>


More information about the llvm-commits mailing list