diff options
author | Guo Ci <zguoci@gmail.com> | 2023-06-19 21:26:15 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-06-19 20:26:15 -0500 |
commit | 7651874a98982430258c4c037221229b92ca69d7 (patch) | |
tree | fd4d3f492f5d0cef6344f718425a436ab955f476 /lib/compilers/argument-parsers.ts | |
parent | c8b131cf2d445e2b296167cfa72c3e47d08ba76a (diff) | |
download | compiler-explorer-7651874a98982430258c4c037221229b92ca69d7.tar.gz compiler-explorer-7651874a98982430258c4c037221229b92ca69d7.zip |
add Stack Usage Viewer (#5160)gh-7881
For #4834
Diffstat (limited to 'lib/compilers/argument-parsers.ts')
-rw-r--r-- | lib/compilers/argument-parsers.ts | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/compilers/argument-parsers.ts b/lib/compilers/argument-parsers.ts index f3756203c..b528f8a55 100644 --- a/lib/compilers/argument-parsers.ts +++ b/lib/compilers/argument-parsers.ts @@ -161,6 +161,10 @@ export class GCCParser extends BaseParser { if (this.hasSupport(options, '-masm=')) { await this.checkAndSetMasmIntelIfSupported(compiler); } + if (this.hasSupport(options, '-fstack-usage')) { + compiler.compiler.stackUsageArg = '-fstack-usage'; + compiler.compiler.supportsStackUsageOutput = true; + } if (this.hasSupport(options, '-fdiagnostics-color')) { if (compiler.compiler.options) compiler.compiler.options += ' '; compiler.compiler.options += '-fdiagnostics-color=always'; @@ -255,6 +259,11 @@ export class ClangParser extends BaseParser { compiler.compiler.optArg = '-fsave-optimization-record'; compiler.compiler.supportsOptOutput = true; } + if (this.hasSupport(options, '-fstack-usage')) { + compiler.compiler.stackUsageArg = '-fstack-usage'; + compiler.compiler.supportsStackUsageOutput = true; + } + if (this.hasSupport(options, '-emit-llvm')) { compiler.compiler.supportsIrView = true; compiler.compiler.irArg = ['-Xclang', '-emit-llvm', '-fsyntax-only']; |