scc

A fork of https://git.simple-cc.org/scc/ for Qute

git clone https://git.8pit.net/scc.git

  1.TH SCC-CC1 1 scc\-VERSION
  2.SH NAME
  3scc-cc1 \- C compiler frontend
  4.SH SYNOPSIS
  5.B cc1
  6.RB [ \-Ewd ]
  7.RB [ \-M ]
  8.RB [ \-a
  9.IR architecture ]
 10.RB [ \-D
 11.IR def[=val] ] ...
 12.RB [ \-U
 13.IR def ] ...
 14.RB [ \-I
 15.IR dir ] ...
 16.RI [ input ]
 17.SH DESCRIPTION
 18.B cc1
 19is the C compiler frontend of the scc toolchain.
 20It reads a C source file (or standard input if no
 21.I input
 22file is given), performs preprocessing, parsing, type checking,
 23and semantic analysis, and emits the scc intermediate representation (IR)
 24to standard output.
 25.PP
 26.B cc1
 27is not normally invoked directly.
 28It is called by the compiler driver
 29.BR scc\-cc (1),
 30which pipes its output to
 31.BR cc2 ,
 32the code generation backend that produces assembly output.
 33.B cc1
 34is installed as
 35.IR $prefix /libexec/scc/cc1.
 36.SH OPTIONS
 37.TP
 38.BI \-a " architecture"
 39Select the target architecture.
 40The following architectures are supported:
 41.RS
 42.TP
 43.B amd64-sysv
 4464-bit x86 with the System V ABI (default).
 45.TP
 46.B arm64-sysv
 4764-bit ARM with the System V ABI.
 48.TP
 49.B riscv64-sysv
 5064-bit RISC-V with the System V ABI.
 51.TP
 52.B i386-sysv
 5332-bit x86 with the System V ABI.
 54.TP
 55.B z80-scc
 56Zilog Z80 with the scc ABI.
 57.RE
 58.TP
 59.BI \-D " def[=val]"
 60Define the preprocessor macro
 61.I def
 62with an optional value
 63.IR val .
 64If
 65.I val
 66is omitted, the macro is defined with the value
 67.BR 1 .
 68This option may be repeated to define multiple macros.
 69.TP
 70.B \-E
 71Stop after preprocessing.
 72Emit the preprocessed C source to standard output instead of IR.
 73No compilation is performed.
 74.TP
 75.BI \-I " dir"
 76Prepend
 77.I dir
 78to the list of directories searched for header files.
 79This option may be repeated to add multiple directories.
 80User-specified directories are searched before any system include directories
 81added by
 82.BR scc\-cc (1).
 83.TP
 84.B \-M
 85Emit a
 86.BR make (1)
 87dependency rule describing the
 88.B #include
 89dependencies of the input file, then exit.
 90No compilation is performed.
 91.TP
 92.BI \-U " def"
 93Undefine the preprocessor macro
 94.IR def .
 95This option may be repeated.
 96.TP
 97.B \-d
 98Enable internal debug output.
 99.TP
100.B \-w
101Enable warning messages for dubious constructs.
102.SH OUTPUT
103.B cc1
104writes the scc IR to standard output.
105The IR is a line-oriented, tab-separated format.
106Declarations begin in column 0; expressions are indented with a tab
107and written in reverse Polish notation.
108For a full description of the IR format, types, storage classes,
109and statement encoding, see
110.BR scc\-ir (7).
111.PP
112When only preprocessing is requested
113.RB ( \-E
114or
115.BR \-M ),
116the preprocessed source or dependency rule is written to standard output
117instead.
118.PP
119If any compilation error occurs, the output stream is closed immediately
120so that the backend
121.B cc2
122receives no output and can detect the failure.
123.B cc1
124exits with a non-zero status on error.
125.SH SEE ALSO
126.BR scc\-cc (1),
127.BR scc\-cpp (1),
128.BR scc (1),
129.BR scc\-cc2 (1),
130.BR scc\-ir (7)