[SafeStack] Insert the deref before remaining elements
authorPetr Hosek <phosek@chromium.org>
Wed, 24 Jul 2019 00:16:23 +0000 (00:16 +0000)
committerPetr Hosek <phosek@chromium.org>
Wed, 24 Jul 2019 00:16:23 +0000 (00:16 +0000)
commit8b161bacf413d2e4f133b3dea121f1d7ae9301b7
tree47e1b91029026daaa5d92147cda3c90ce2548f10
parent4287c95b08ab9b10cce50ab8139f536ea2d72f1d
[SafeStack] Insert the deref before remaining elements

This is a follow up to D64971. While we need to insert the deref after
the offset, it needs to come before the remaining elements in the
original expression since the deref needs to happen before the LLVM
fragment if present.

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

llvm-svn: 366865
llvm/lib/Transforms/Utils/Local.cpp
llvm/test/Transforms/SafeStack/X86/debug-loc2.ll