[PATCH] D51201: [MIR] Add hasWinCFI field
Sanjin Sijaric via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Oct 19 15:09:01 PDT 2018
ssijaric updated this revision to Diff 170259.
ssijaric retitled this revision from "[MIRParser] Add hasWinCFI field" to "[MIR] Add hasWinCFI field".
ssijaric added a comment.
Add hasWinCFI to MIRPrinter as well, now that HasWinCFI is a plain bool.
Repository:
rL LLVM
https://reviews.llvm.org/D51201
Files:
include/llvm/CodeGen/MIRYamlMapping.h
lib/CodeGen/MIRParser/MIRParser.cpp
lib/CodeGen/MIRPrinter.cpp
Index: lib/CodeGen/MIRPrinter.cpp
===================================================================
--- lib/CodeGen/MIRPrinter.cpp
+++ lib/CodeGen/MIRPrinter.cpp
@@ -196,6 +196,7 @@
YamlMF.Name = MF.getName();
YamlMF.Alignment = MF.getAlignment();
YamlMF.ExposesReturnsTwice = MF.exposesReturnsTwice();
+ YamlMF.HasWinCFI = MF.hasWinCFI();
YamlMF.Legalized = MF.getProperties().hasProperty(
MachineFunctionProperties::Property::Legalized);
Index: lib/CodeGen/MIRParser/MIRParser.cpp
===================================================================
--- lib/CodeGen/MIRParser/MIRParser.cpp
+++ lib/CodeGen/MIRParser/MIRParser.cpp
@@ -355,6 +355,7 @@
if (YamlMF.Alignment)
MF.setAlignment(YamlMF.Alignment);
MF.setExposesReturnsTwice(YamlMF.ExposesReturnsTwice);
+ MF.setHasWinCFI(YamlMF.HasWinCFI);
if (YamlMF.Legalized)
MF.getProperties().set(MachineFunctionProperties::Property::Legalized);
Index: include/llvm/CodeGen/MIRYamlMapping.h
===================================================================
--- include/llvm/CodeGen/MIRYamlMapping.h
+++ include/llvm/CodeGen/MIRYamlMapping.h
@@ -489,6 +489,7 @@
bool FailedISel = false;
// Register information
bool TracksRegLiveness = false;
+ bool HasWinCFI = false;
std::vector<VirtualRegisterDefinition> VirtualRegisters;
std::vector<MachineFunctionLiveIn> LiveIns;
Optional<std::vector<FlowStringValue>> CalleeSavedRegisters;
@@ -512,6 +513,7 @@
YamlIO.mapOptional("selected", MF.Selected, false);
YamlIO.mapOptional("failedISel", MF.FailedISel, false);
YamlIO.mapOptional("tracksRegLiveness", MF.TracksRegLiveness, false);
+ YamlIO.mapOptional("hasWinCFI", MF.HasWinCFI, false);
YamlIO.mapOptional("registers", MF.VirtualRegisters,
std::vector<VirtualRegisterDefinition>());
YamlIO.mapOptional("liveins", MF.LiveIns,
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D51201.170259.patch
Type: text/x-patch
Size: 1889 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20181019/3558f01e/attachment.bin>
More information about the llvm-commits
mailing list