Adds new cpu architectures propeller1 and propeller2. (#21563)
* Adds new cpu architectures propeller1 and propeller2. These cpu architectures allow targeting the Parallax Propeller 1 and Propeller 2, which are both very special microcontrollers with 512 registers and 8 cpu cores. Resolves #21559 * Adds std.elf.EM.PROPELLER and std.elf.EM.PROPELLER2 * Fixes missing switch prongs in src/codegen/llvm.zig * Fixes order in std.Target.Arch --------- Co-authored-by: Felix "xq" Queißner <git@random-projects.net>
This commit is contained in:
@@ -88,7 +88,10 @@ pub fn targetTriple(allocator: Allocator, target: std.Target) ![]const u8 {
|
||||
|
||||
.kalimba,
|
||||
.spu_2,
|
||||
.propeller1,
|
||||
.propeller2,
|
||||
=> unreachable, // Gated by hasLlvmSupport().
|
||||
|
||||
};
|
||||
try llvm_triple.appendSlice(llvm_arch);
|
||||
|
||||
@@ -281,7 +284,7 @@ pub fn targetArch(arch_tag: std.Target.Cpu.Arch) llvm.ArchType {
|
||||
.wasm32 => .wasm32,
|
||||
.wasm64 => .wasm64,
|
||||
.ve => .ve,
|
||||
.spu_2 => .UnknownArch,
|
||||
.propeller1, .propeller2, .spu_2 => .UnknownArch,
|
||||
};
|
||||
}
|
||||
|
||||
@@ -12714,6 +12717,8 @@ pub fn initializeLLVMTarget(arch: std.Target.Cpu.Arch) void {
|
||||
// LLVM does does not have a backend for these.
|
||||
.kalimba,
|
||||
.spu_2,
|
||||
.propeller1,
|
||||
.propeller2,
|
||||
=> unreachable,
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1856,6 +1856,9 @@ const NavGen = struct {
|
||||
.flash3,
|
||||
.flash4,
|
||||
.flash5,
|
||||
.cog,
|
||||
.lut,
|
||||
.hub,
|
||||
=> unreachable,
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user