1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2025-01-31 12:41:49 +01:00

[NewPM][opt] Fix -globals-aa not being recognized as alias analysis in NPM

Was missing MODULE_ALIAS_ANALYSIS, previously only FUNCTION_ALIAS_ANALYSIS was taken into account.

Reviewed By: asbirlea

Differential Revision: https://reviews.llvm.org/D87664
This commit is contained in:
Arthur Eubanks 2020-09-14 18:35:12 -07:00
parent 6c10abc35d
commit 0328e43463
2 changed files with 5 additions and 1 deletions

View File

@ -2787,6 +2787,9 @@ Error PassBuilder::parseAAPipeline(AAManager &AA, StringRef PipelineText) {
}
bool PassBuilder::isAAPassName(StringRef PassName) {
#define MODULE_ALIAS_ANALYSIS(NAME, CREATE_PASS) \
if (PassName == NAME) \
return true;
#define FUNCTION_ALIAS_ANALYSIS(NAME, CREATE_PASS) \
if (PassName == NAME) \
return true;

View File

@ -1,4 +1,5 @@
; RUN: opt < %s -basic-aa -globals-aa -gvn -S | FileCheck %s
; RUN: opt < %s -basic-aa -globals-aa -gvn -enable-new-pm=0 -S | FileCheck %s
; RUN: opt < %s -basic-aa -globals-aa -gvn -enable-new-pm=1 -S | FileCheck %s
; See PR26774