aboutsummaryrefslogtreecommitdiff
path: root/backend/include/rcc/MIR
diff options
context:
space:
mode:
authorRichard-Qin-X <richard.qin.001@gmail.com>2026-08-25 02:21:25 +0800
committerRichard-Qin-X <richard.qin.001@gmail.com>2026-08-25 02:21:25 +0800
commit71988f9818677df0d90b19d4bb770ac8a6116e62 (patch)
treeabc6a548dc50fefd1e2882fd33fe652776c0bb6a /backend/include/rcc/MIR
parent6dc798fbdbef20670317742a8c1d12f47e9d1c05 (diff)
downloadrcc-project-71988f9818677df0d90b19d4bb770ac8a6116e62.tar.gz
rcc-project-71988f9818677df0d90b19d4bb770ac8a6116e62.tar.xz
[CodeGen] Implement RISC-V machine outlining
Diffstat (limited to 'backend/include/rcc/MIR')
-rw-r--r--backend/include/rcc/MIR/EmbeddedIR.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/backend/include/rcc/MIR/EmbeddedIR.h b/backend/include/rcc/MIR/EmbeddedIR.h
index 022f121..80e512a 100644
--- a/backend/include/rcc/MIR/EmbeddedIR.h
+++ b/backend/include/rcc/MIR/EmbeddedIR.h
@@ -58,6 +58,22 @@ public:
return IsUnnamed;
}
+ [[nodiscard]] bool hasLinkOnceODRLinkage() const noexcept {
+ return HasLinkOnceODRLinkage;
+ }
+
+ [[nodiscard]] bool hasSection() const noexcept {
+ return HasSection;
+ }
+
+ [[nodiscard]] bool hasComdat() const noexcept {
+ return HasComdat;
+ }
+
+ [[nodiscard]] bool hasSectionPrefix() const noexcept {
+ return HasSectionPrefix;
+ }
+
[[nodiscard]] std::span<const EmbeddedIRReference> blocks() const noexcept {
return Blocks;
}
@@ -87,6 +103,10 @@ private:
TextRange NameRange;
bool IsDefinition = false;
bool IsUnnamed = false;
+ bool HasLinkOnceODRLinkage = false;
+ bool HasSection = false;
+ bool HasComdat = false;
+ bool HasSectionPrefix = false;
std::uint64_t NextUnnamedSlot = 0;
std::vector<EmbeddedIRReference> Blocks;
std::vector<EmbeddedIRReference> Allocas;