diff options
author | Jeremy Rifkin <51220084+jeremy-rifkin@users.noreply.github.com> | 2023-06-11 17:00:53 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-06-11 17:00:53 -0400 |
commit | 10851a1ddaea3e1111ea9f50afba1ff993a0967b (patch) | |
tree | 9792df118f580afb5988a607ce048244455be2c5 /lib/compilers/typescript-native.ts | |
parent | 79bba4c1d1031fa250919539e7681cfcba250b7a (diff) | |
download | compiler-explorer-10851a1ddaea3e1111ea9f50afba1ff993a0967b.tar.gz compiler-explorer-10851a1ddaea3e1111ea9f50afba1ff993a0967b.zip |
LLVM IR pane improvements (#5078)gh-7669
This PR will add filtering and other output options to the LLVM IR pane


Closes #5062
Related to #5045
Diffstat (limited to 'lib/compilers/typescript-native.ts')
-rw-r--r-- | lib/compilers/typescript-native.ts | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/lib/compilers/typescript-native.ts b/lib/compilers/typescript-native.ts index d450bcb94..adf3db24d 100644 --- a/lib/compilers/typescript-native.ts +++ b/lib/compilers/typescript-native.ts @@ -31,6 +31,7 @@ import {BaseCompiler} from '../base-compiler.js'; import {asSafeVer} from '../utils.js'; import {TypeScriptNativeParser} from './argument-parsers.js'; +import {LLVMIrBackendOptions} from '../../types/compilation/ir.interfaces.js'; export class TypeScriptNativeCompiler extends BaseCompiler { static get key() { @@ -105,7 +106,12 @@ export class TypeScriptNativeCompiler extends BaseCompiler { return {code: 0, timedOut: false, stdout: [], stderr: []}; } - override async generateIR(inputFilename: string, options: string[], filters: ParseFiltersAndOutputOptions) { + override async generateIR( + inputFilename: string, + options: string[], + irOptions: LLVMIrBackendOptions, + filters: ParseFiltersAndOutputOptions, + ) { // These options make Clang produce an IR let newOptions = ['--emit=llvm', inputFilename]; if (this.tscNewOutput) { @@ -134,7 +140,7 @@ export class TypeScriptNativeCompiler extends BaseCompiler { filters.libraryCode = true; filters.directives = true; - const ir = await this.llvmIr.process(this.tscNewOutput ? output.stdout : output.stderr, filters); + const ir = await this.llvmIr.process(this.tscNewOutput ? output.stdout : output.stderr, irOptions); return ir.asm; } |