public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* "position independent" vs "position-independent" in documentation
@ 2018-04-30 19:02 Jonathan Wakely
  2018-05-01  4:12 ` Sandra Loosemore
  0 siblings, 1 reply; 3+ messages in thread
From: Jonathan Wakely @ 2018-04-30 19:02 UTC (permalink / raw)
  To: gcc

Should we standardize on "position-independent" and add it to
https://gcc.gnu.org/codingconventions.html#Spelling ?


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: "position independent" vs "position-independent" in documentation
  2018-04-30 19:02 "position independent" vs "position-independent" in documentation Jonathan Wakely
@ 2018-05-01  4:12 ` Sandra Loosemore
  2018-05-01 10:17   ` Jonathan Wakely
  0 siblings, 1 reply; 3+ messages in thread
From: Sandra Loosemore @ 2018-05-01  4:12 UTC (permalink / raw)
  To: Jonathan Wakely, gcc

On 04/30/2018 05:56 AM, Jonathan Wakely wrote:
> Should we standardize on "position-independent" and add it to
> https://gcc.gnu.org/codingconventions.html#Spelling ?

The same generic English usage rules apply here as to other compound 
phrases; hyphenate when immediately before a noun, don't hyphenate in 
other contexts.  So "the compiler generates position-independent code" 
and "the compiler generates code that is position independent" are both 
correct.  However, I don't think it's common to use "position 
independent" (hyphenated or not) except as a modifier for "code", so you 
could add "position-independent code" (rather than just 
"position-independent") to the glossary.

-Sandra

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: "position independent" vs "position-independent" in documentation
  2018-05-01  4:12 ` Sandra Loosemore
@ 2018-05-01 10:17   ` Jonathan Wakely
  0 siblings, 0 replies; 3+ messages in thread
From: Jonathan Wakely @ 2018-05-01 10:17 UTC (permalink / raw)
  To: Sandra Loosemore; +Cc: gcc

On 30/04/18 22:12 -0600, Sandra Loosemore wrote:
>On 04/30/2018 05:56 AM, Jonathan Wakely wrote:
>>Should we standardize on "position-independent" and add it to
>>https://gcc.gnu.org/codingconventions.html#Spelling ?
>
>The same generic English usage rules apply here as to other compound 
>phrases; hyphenate when immediately before a noun, don't hyphenate in 
>other contexts.  So "the compiler generates position-independent code" 
>and "the compiler generates code that is position independent" are 
>both correct.

Or we could decide that "position-independent" should always be
hyphenated as it's a commonly established adjective. I'm not arguing
in favour of that, but it's how it's used in some of the docs already.

>However, I don't think it's common to use "position 
>independent" (hyphenated or not) except as a modifier for "code", so 
>you could add "position-independent code" (rather than just 
>"position-independent") to the glossary.

We have several of uses of "position independent executable" and
one "position independent data" which should be hyphenated.

Ignoring all the uses of "position-independent code" that already have
a hyphen we're left with the following and none of them is correct!

--
gcc/doc/invoke.texi-@opindex pie
gcc/doc/invoke.texi:Produce a dynamically linked position independent executable on targets
gcc/doc/invoke.texi-that support it.  For predictable results, you must also specify the same
--
gcc/doc/invoke.texi-@opindex no-pie
gcc/doc/invoke.texi:Don't produce a dynamically linked position independent executable.
gcc/doc/invoke.texi-
--
gcc/doc/invoke.texi-@opindex static-pie
gcc/doc/invoke.texi:Produce a static position independent executable on targets that support
gcc/doc/invoke.texi:it.  A static position independent executable is similar to a static
gcc/doc/invoke.texi-executable, but can be loaded at any address without a dynamic linker.
--
gcc/doc/invoke.texi-but not for the Sun 386i.  Code generated for the IBM RS/6000 is always
gcc/doc/invoke.texi:position-independent.
gcc/doc/invoke.texi-
--
gcc/doc/invoke.texi-Generate code that does not use a global pointer register.  The result
gcc/doc/invoke.texi:is not position independent code, and violates the IA-64 ABI@.
gcc/doc/invoke.texi-
--
gcc/doc/invoke.texi-@itemx -mno-shared
gcc/doc/invoke.texi:Generate (do not generate) code that is fully position-independent,
gcc/doc/invoke.texi-and that can therefore be linked into shared libraries.  This option
--
gcc/doc/invoke.texi-
gcc/doc/invoke.texi:All @option{-mabicalls} code has traditionally been position-independent,
gcc/doc/invoke.texi-regardless of options like @option{-fPIC} and @option{-fpic}.  However,
--
gcc/doc/invoke.texi-@opindex mno-pid
gcc/doc/invoke.texi:Enables the generation of position independent data.  When enabled any
gcc/doc/invoke.texi-access to constant data is done via an offset from a base address
--
gcc/doc/md.texi-Constant for arithmetic/logical operations.
gcc/doc/md.texi:This is like @code{i}, except that for position independent code,
gcc/doc/md.texi-no symbols / expressions needing relocations are allowed.
--
gcc/doc/tm.texi-* Sections::            Dividing storage into text, data, and other sections.
gcc/doc/tm.texi:* PIC::                 Macros for position independent code.
gcc/doc/tm.texi-* Assembler Format::    Defining how to write insns and pseudo-ops to output.
--
gcc/doc/tm.texi-@section Position Independent Code
gcc/doc/tm.texi:@cindex position independent code
gcc/doc/tm.texi-@cindex PIC
--
gcc/doc/tm.texi-A C expression that is nonzero if @var{x} is a legitimate immediate
gcc/doc/tm.texi:operand on the target machine when generating position independent code.
gcc/doc/tm.texi-You can assume that @var{x} satisfies @code{CONSTANT_P}, so you need not
--
gcc/doc/tm.texi-(including @code{SYMBOL_REF}) can be immediate operands when generating
gcc/doc/tm.texi:position independent code.
gcc/doc/tm.texi-@end defmac
--
gcc/doc/tm.texi.in-* Sections::            Dividing storage into text, data, and other sections.
gcc/doc/tm.texi.in:* PIC::                 Macros for position independent code.
gcc/doc/tm.texi.in-* Assembler Format::    Defining how to write insns and pseudo-ops to output.
--
gcc/doc/tm.texi.in-@section Position Independent Code
gcc/doc/tm.texi.in:@cindex position independent code
gcc/doc/tm.texi.in-@cindex PIC
--
gcc/doc/tm.texi.in-A C expression that is nonzero if @var{x} is a legitimate immediate
gcc/doc/tm.texi.in:operand on the target machine when generating position independent code.
gcc/doc/tm.texi.in-You can assume that @var{x} satisfies @code{CONSTANT_P}, so you need not
--
gcc/doc/tm.texi.in-(including @code{SYMBOL_REF}) can be immediate operands when generating
gcc/doc/tm.texi.in:position independent code.
gcc/doc/tm.texi.in-@end defmac


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2018-05-01 10:17 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-04-30 19:02 "position independent" vs "position-independent" in documentation Jonathan Wakely
2018-05-01  4:12 ` Sandra Loosemore
2018-05-01 10:17   ` Jonathan Wakely

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).