Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
LLVM bpEVL
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Lorenzo Albano
LLVM bpEVL
Commits
a7bcad46
Commit
a7bcad46
authored
11 years ago
by
Rui Ueyama
Browse files
Options
Downloads
Patches
Plain Diff
[PECOFF] Remove redundant comments.
llvm-svn: 191270
parent
c583d17a
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
lld/lib/Driver/WinLinkDriver.cpp
+12
-23
12 additions, 23 deletions
lld/lib/Driver/WinLinkDriver.cpp
with
12 additions
and
23 deletions
lld/lib/Driver/WinLinkDriver.cpp
+
12
−
23
View file @
a7bcad46
...
@@ -309,9 +309,9 @@ bool WinLinkDriver::parse(int argc, const char *argv[], PECOFFLinkingContext &ct
...
@@ -309,9 +309,9 @@ bool WinLinkDriver::parse(int argc, const char *argv[], PECOFFLinkingContext &ct
case
OPT_base
:
case
OPT_base
:
// Parse /base command line option. The argument for the parameter is in
// Parse /base command line option. The argument for the parameter is in
// the
// the form of "<address>[:<size>]".
// form of "<address>[:<size>]".
uint64_t
addr
,
size
;
uint64_t
addr
,
size
;
// Size should be set to SizeOfImage field in the COFF header, and if
// Size should be set to SizeOfImage field in the COFF header, and if
// it's smaller than the actual size, the linker should warn about that.
// it's smaller than the actual size, the linker should warn about that.
// Currently we just ignore the value of size parameter.
// Currently we just ignore the value of size parameter.
...
@@ -319,6 +319,7 @@ bool WinLinkDriver::parse(int argc, const char *argv[], PECOFFLinkingContext &ct
...
@@ -319,6 +319,7 @@ bool WinLinkDriver::parse(int argc, const char *argv[], PECOFFLinkingContext &ct
return
true
;
return
true
;
ctx
.
setBaseAddress
(
addr
);
ctx
.
setBaseAddress
(
addr
);
break
;
break
;
case
OPT_stack
:
{
case
OPT_stack
:
{
// Parse /stack command line option
// Parse /stack command line option
uint64_t
reserve
;
uint64_t
reserve
;
...
@@ -329,6 +330,7 @@ bool WinLinkDriver::parse(int argc, const char *argv[], PECOFFLinkingContext &ct
...
@@ -329,6 +330,7 @@ bool WinLinkDriver::parse(int argc, const char *argv[], PECOFFLinkingContext &ct
ctx
.
setStackCommit
(
commit
);
ctx
.
setStackCommit
(
commit
);
break
;
break
;
}
}
case
OPT_heap
:
{
case
OPT_heap
:
{
// Parse /heap command line option
// Parse /heap command line option
uint64_t
reserve
;
uint64_t
reserve
;
...
@@ -339,6 +341,7 @@ bool WinLinkDriver::parse(int argc, const char *argv[], PECOFFLinkingContext &ct
...
@@ -339,6 +341,7 @@ bool WinLinkDriver::parse(int argc, const char *argv[], PECOFFLinkingContext &ct
ctx
.
setHeapCommit
(
commit
);
ctx
.
setHeapCommit
(
commit
);
break
;
break
;
}
}
case
OPT_align
:
{
case
OPT_align
:
{
uint32_t
align
;
uint32_t
align
;
StringRef
arg
=
inputArg
->
getValue
();
StringRef
arg
=
inputArg
->
getValue
();
...
@@ -349,6 +352,7 @@ bool WinLinkDriver::parse(int argc, const char *argv[], PECOFFLinkingContext &ct
...
@@ -349,6 +352,7 @@ bool WinLinkDriver::parse(int argc, const char *argv[], PECOFFLinkingContext &ct
ctx
.
setSectionAlignment
(
align
);
ctx
.
setSectionAlignment
(
align
);
break
;
break
;
}
}
case
OPT_machine
:
{
case
OPT_machine
:
{
StringRef
arg
=
inputArg
->
getValue
();
StringRef
arg
=
inputArg
->
getValue
();
llvm
::
COFF
::
MachineTypes
type
=
stringToMachineType
(
arg
);
llvm
::
COFF
::
MachineTypes
type
=
stringToMachineType
(
arg
);
...
@@ -359,6 +363,7 @@ bool WinLinkDriver::parse(int argc, const char *argv[], PECOFFLinkingContext &ct
...
@@ -359,6 +363,7 @@ bool WinLinkDriver::parse(int argc, const char *argv[], PECOFFLinkingContext &ct
ctx
.
setMachineType
(
type
);
ctx
.
setMachineType
(
type
);
break
;
break
;
}
}
case
OPT_version
:
{
case
OPT_version
:
{
uint32_t
major
,
minor
;
uint32_t
major
,
minor
;
if
(
parseVersion
(
inputArg
->
getValue
(),
major
,
minor
))
if
(
parseVersion
(
inputArg
->
getValue
(),
major
,
minor
))
...
@@ -366,6 +371,7 @@ bool WinLinkDriver::parse(int argc, const char *argv[], PECOFFLinkingContext &ct
...
@@ -366,6 +371,7 @@ bool WinLinkDriver::parse(int argc, const char *argv[], PECOFFLinkingContext &ct
ctx
.
setImageVersion
(
PECOFFLinkingContext
::
Version
(
major
,
minor
));
ctx
.
setImageVersion
(
PECOFFLinkingContext
::
Version
(
major
,
minor
));
break
;
break
;
}
}
case
OPT_subsystem
:
{
case
OPT_subsystem
:
{
// Parse /subsystem command line option. The form of /subsystem is
// Parse /subsystem command line option. The form of /subsystem is
// "subsystem_name[,majorOSVersion[.minorOSVersion]]".
// "subsystem_name[,majorOSVersion[.minorOSVersion]]".
...
@@ -397,12 +403,10 @@ bool WinLinkDriver::parse(int argc, const char *argv[], PECOFFLinkingContext &ct
...
@@ -397,12 +403,10 @@ bool WinLinkDriver::parse(int argc, const char *argv[], PECOFFLinkingContext &ct
break
;
break
;
case
OPT_entry
:
case
OPT_entry
:
// handle /entry
ctx
.
setEntrySymbolName
(
ctx
.
allocateString
(
inputArg
->
getValue
()));
ctx
.
setEntrySymbolName
(
ctx
.
allocateString
(
inputArg
->
getValue
()));
break
;
break
;
case
OPT_libpath
:
case
OPT_libpath
:
// handle /libpath
ctx
.
appendInputSearchPath
(
ctx
.
allocateString
(
inputArg
->
getValue
()));
ctx
.
appendInputSearchPath
(
ctx
.
allocateString
(
inputArg
->
getValue
()));
break
;
break
;
...
@@ -414,90 +418,75 @@ bool WinLinkDriver::parse(int argc, const char *argv[], PECOFFLinkingContext &ct
...
@@ -414,90 +418,75 @@ bool WinLinkDriver::parse(int argc, const char *argv[], PECOFFLinkingContext &ct
case
OPT_force
:
case
OPT_force
:
case
OPT_force_unresolved
:
case
OPT_force_unresolved
:
//
handle
/force
or
/force:unresolved. We do not currently
support
// /force
and
/force:unresolved
mean the same thing
. We do not currently
// /force:multiple.
//
support
/force:multiple.
ctx
.
setAllowRemainingUndefines
(
true
);
ctx
.
setAllowRemainingUndefines
(
true
);
break
;
break
;
case
OPT_no_ref
:
case
OPT_no_ref
:
// Handle /opt:noref
ctx
.
setDeadStripping
(
false
);
ctx
.
setDeadStripping
(
false
);
break
;
break
;
case
OPT_nxcompat_no
:
case
OPT_nxcompat_no
:
// handle /nxcompat:no
ctx
.
setNxCompat
(
false
);
ctx
.
setNxCompat
(
false
);
break
;
break
;
case
OPT_largeaddressaware
:
case
OPT_largeaddressaware
:
// handle /largeaddressaware
ctx
.
setLargeAddressAware
(
true
);
ctx
.
setLargeAddressAware
(
true
);
break
;
break
;
case
OPT_allowbind
:
case
OPT_allowbind
:
// handle /allowbind
ctx
.
setAllowBind
(
true
);
ctx
.
setAllowBind
(
true
);
break
;
break
;
case
OPT_allowbind_no
:
case
OPT_allowbind_no
:
// handle /allowbind:no
ctx
.
setAllowBind
(
false
);
ctx
.
setAllowBind
(
false
);
break
;
break
;
case
OPT_allowisolation
:
case
OPT_allowisolation
:
// handle /allowisolation
ctx
.
setAllowIsolation
(
true
);
ctx
.
setAllowIsolation
(
true
);
break
;
break
;
case
OPT_allowisolation_no
:
case
OPT_allowisolation_no
:
// handle /allowisolation:no
ctx
.
setAllowIsolation
(
false
);
ctx
.
setAllowIsolation
(
false
);
break
;
break
;
case
OPT_fixed
:
case
OPT_fixed
:
// handle /fixed
// /fixed is not compatible with /dynamicbase. Check for it.
// make sure /dynamicbase wasn't specified
if
(
parsedArgs
->
getLastArg
(
OPT_dynamicbase
))
{
if
(
parsedArgs
->
getLastArg
(
OPT_dynamicbase
))
{
diagnostics
<<
"/dynamicbase must not be specified with /fixed
\n
"
;
diagnostics
<<
"/dynamicbase must not be specified with /fixed
\n
"
;
return
true
;
return
true
;
}
}
ctx
.
setBaseRelocationEnabled
(
false
);
ctx
.
setBaseRelocationEnabled
(
false
);
ctx
.
setDynamicBaseEnabled
(
false
);
ctx
.
setDynamicBaseEnabled
(
false
);
break
;
break
;
case
OPT_dynamicbase_no
:
case
OPT_dynamicbase_no
:
// handle /dynamicbase:no
ctx
.
setDynamicBaseEnabled
(
false
);
ctx
.
setDynamicBaseEnabled
(
false
);
break
;
break
;
case
OPT_tsaware
:
case
OPT_tsaware
:
// handle /tsaware
ctx
.
setTerminalServerAware
(
true
);
ctx
.
setTerminalServerAware
(
true
);
break
;
break
;
case
OPT_tsaware_no
:
case
OPT_tsaware_no
:
// handle /tsaware:no
ctx
.
setTerminalServerAware
(
false
);
ctx
.
setTerminalServerAware
(
false
);
break
;
break
;
case
OPT_incl
:
case
OPT_incl
:
// handle /incl
ctx
.
addInitialUndefinedSymbol
(
ctx
.
allocateString
(
inputArg
->
getValue
()));
ctx
.
addInitialUndefinedSymbol
(
ctx
.
allocateString
(
inputArg
->
getValue
()));
break
;
break
;
case
OPT_nodefaultlib_all
:
case
OPT_nodefaultlib_all
:
// handle /nodefaultlib
ctx
.
setNoDefaultLibAll
(
true
);
ctx
.
setNoDefaultLibAll
(
true
);
break
;
break
;
case
OPT_out
:
case
OPT_out
:
// handle /out
ctx
.
setOutputPath
(
ctx
.
allocateString
(
inputArg
->
getValue
()));
ctx
.
setOutputPath
(
ctx
.
allocateString
(
inputArg
->
getValue
()));
break
;
break
;
case
OPT_INPUT
:
case
OPT_INPUT
:
// Add an input file.
inputGraph
.
addInputElement
(
std
::
unique_ptr
<
InputElement
>
(
inputGraph
.
addInputElement
(
std
::
unique_ptr
<
InputElement
>
(
new
PECOFFFileNode
(
ctx
,
inputArg
->
getValue
())));
new
PECOFFFileNode
(
ctx
,
inputArg
->
getValue
())));
break
;
break
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment