Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
go
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
go
Commits
12923e43
Commit
12923e43
authored
May 28, 2010
by
Alex Brainman
Committed by
Russ Cox
May 28, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
syscall: windows syscall trace to assist debugging
R=golang-dev, rsc CC=golang-dev
https://golang.org/cl/1383041
parent
0580deaf
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
0 deletions
+7
-0
src/pkg/syscall/mksyscall_windows.sh
src/pkg/syscall/mksyscall_windows.sh
+7
-0
No files found.
src/pkg/syscall/mksyscall_windows.sh
View file @
12923e43
...
...
@@ -112,6 +112,7 @@ while(<>) {
# Prepare arguments to Syscall.
my @args
=
()
;
my
$n
=
0
;
my @pin
=
()
;
foreach my
$p
(
@in
)
{
my
(
$name
,
$type
)
=
parseparam
(
$p
)
;
if
(
$type
=
~ /^
\*
/
)
{
...
...
@@ -135,6 +136,7 @@ while(<>) {
}
else
{
push @args,
"uintptr(
$name
)"
;
}
push @pin, sprintf
"
\"
%s=
\"
, %s, "
,
$name
,
$name
;
}
# Determine which form to use; pad args with zeros.
...
...
@@ -165,6 +167,7 @@ while(<>) {
my
$body
=
""
;
my
$failexpr
=
""
;
my @ret
=
(
"_"
,
"_"
,
"_"
)
;
my @pout
=
()
;
for
(
my
$i
=
0
;
$i
<@out
;
$i
++
)
{
my
$p
=
$out
[
$i
]
;
my
(
$name
,
$type
)
=
parseparam
(
$p
)
;
...
...
@@ -209,6 +212,7 @@ while(<>) {
}
else
{
$body
.
=
"
\t
$name
=
$type
(
$reg
);
\n
"
;
}
push @pout, sprintf
"
\"
%s=
\"
, %s(%s), "
,
$name
,
$type
,
$reg
;
}
if
(
$ret
[
0] eq
"_"
&&
$ret
[
1] eq
"_"
&&
$ret
[
2] eq
"_"
)
{
$text
.
=
"
\t
$call
;
\n
"
;
...
...
@@ -216,6 +220,9 @@ while(<>) {
$text
.
=
"
\t
$ret
[0],
$ret
[1],
$ret
[2] :=
$call
;
\n
"
;
}
$text
.
=
$body
;
if
(
0
)
{
$text
.
=
sprintf
'print("SYSCALL: %s(", %s") (", %s")\n")%s'
,
$func
,
join
(
'", ", '
, @pin
)
,
join
(
'", ", '
, @pout
)
,
"
\n
"
;
}
$text
.
=
"
\t
return;
\n
"
;
$text
.
=
"}
\n\n
"
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment