Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
Slurm
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
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
Service Desk
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
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
tud-zih-energy
Slurm
Commits
7c19e08d
Commit
7c19e08d
authored
20 years ago
by
Danny Auble
Browse files
Options
Downloads
Patches
Plain Diff
bluegene.conf file is made correctly.
parent
554e1f3b
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
src/smap/configure_functions.c
+34
-19
34 additions, 19 deletions
src/smap/configure_functions.c
with
34 additions
and
19 deletions
src/smap/configure_functions.c
+
34
−
19
View file @
7c19e08d
...
@@ -100,20 +100,20 @@ static int _create_allocation(char *com, List allocated_partitions)
...
@@ -100,20 +100,20 @@ static int _create_allocation(char *com, List allocated_partitions)
pa_request_t
*
request
=
(
pa_request_t
*
)
xmalloc
(
sizeof
(
pa_request_t
));
pa_request_t
*
request
=
(
pa_request_t
*
)
xmalloc
(
sizeof
(
pa_request_t
));
request
->
geometry
[
0
]
=
-
1
;
request
->
geometry
[
0
]
=
-
1
;
request
->
conn_type
=
MESH
;
request
->
conn_type
=
TORUS
;
request
->
rotate
=
false
;
request
->
rotate
=
false
;
request
->
elongate
=
false
;
request
->
elongate
=
false
;
request
->
force_contig
=
false
;
request
->
force_contig
=
false
;
request
->
co_proc
=
fals
e
;
request
->
co_proc
=
tru
e
;
while
(
i
<
len
)
{
while
(
i
<
len
)
{
while
(
com
[
i
-
1
]
!=
' '
&&
i
<
len
)
{
while
(
com
[
i
-
1
]
!=
' '
&&
i
<
len
)
{
i
++
;
i
++
;
}
}
if
(
!
strncasecmp
(
com
+
i
,
"
torus
"
,
5
))
{
if
(
!
strncasecmp
(
com
+
i
,
"
mesh
"
,
4
))
{
request
->
conn_type
=
TORUS
;
request
->
conn_type
=
MESH
;
i
+=
5
;
i
+=
4
;
}
else
if
(
!
strncasecmp
(
com
+
i
,
"rotate"
,
6
))
{
}
else
if
(
!
strncasecmp
(
com
+
i
,
"rotate"
,
6
))
{
request
->
rotate
=
true
;
request
->
rotate
=
true
;
i
+=
6
;
i
+=
6
;
...
@@ -123,9 +123,9 @@ static int _create_allocation(char *com, List allocated_partitions)
...
@@ -123,9 +123,9 @@ static int _create_allocation(char *com, List allocated_partitions)
}
else
if
(
!
strncasecmp
(
com
+
i
,
"force"
,
5
))
{
}
else
if
(
!
strncasecmp
(
com
+
i
,
"force"
,
5
))
{
request
->
force_contig
=
true
;
request
->
force_contig
=
true
;
i
+=
5
;
i
+=
5
;
}
else
if
(
!
strncasecmp
(
com
+
i
,
"
proc
"
,
4
))
{
}
else
if
(
!
strncasecmp
(
com
+
i
,
"
virtual
"
,
7
))
{
request
->
co_proc
=
tru
e
;
request
->
co_proc
=
fals
e
;
i
+=
4
;
i
+=
7
;
}
else
if
(
i2
<
0
&&
(
com
[
i
]
<
58
&&
com
[
i
]
>
47
))
{
}
else
if
(
i2
<
0
&&
(
com
[
i
]
<
58
&&
com
[
i
]
>
47
))
{
i2
=
i
;
i2
=
i
;
i
++
;
i
++
;
...
@@ -253,21 +253,21 @@ static int _remove_allocation(char *com, List allocated_partitions)
...
@@ -253,21 +253,21 @@ static int _remove_allocation(char *com, List allocated_partitions)
static
int
_alter_allocation
(
char
*
com
,
List
allocated_partitions
)
static
int
_alter_allocation
(
char
*
com
,
List
allocated_partitions
)
{
{
int
torus
=
MESH
,
i
=
5
,
i2
=
0
;
int
torus
=
TORUS
,
i
=
5
,
i2
=
0
;
int
len
=
strlen
(
com
);
int
len
=
strlen
(
com
);
bool
rotate
=
false
;
bool
rotate
=
false
;
bool
elongate
=
false
;
bool
elongate
=
false
;
bool
force_contig
=
false
;
bool
force_contig
=
false
;
bool
co_proc
=
fals
e
;
bool
co_proc
=
tru
e
;
while
(
i
<
len
)
{
while
(
i
<
len
)
{
while
(
com
[
i
-
1
]
!=
' '
&&
i
<
len
)
{
while
(
com
[
i
-
1
]
!=
' '
&&
i
<
len
)
{
i
++
;
i
++
;
}
}
if
(
!
strncasecmp
(
com
+
i
,
"
torus
"
,
5
))
{
if
(
!
strncasecmp
(
com
+
i
,
"
mesh
"
,
4
))
{
torus
=
TORUS
;
torus
=
MESH
;
i
+=
5
;
i
+=
4
;
}
else
if
(
!
strncasecmp
(
com
+
i
,
"rotate"
,
6
))
{
}
else
if
(
!
strncasecmp
(
com
+
i
,
"rotate"
,
6
))
{
rotate
=
true
;
rotate
=
true
;
i
+=
6
;
i
+=
6
;
...
@@ -277,9 +277,9 @@ static int _alter_allocation(char *com, List allocated_partitions)
...
@@ -277,9 +277,9 @@ static int _alter_allocation(char *com, List allocated_partitions)
}
else
if
(
!
strncasecmp
(
com
+
i
,
"force"
,
5
))
{
}
else
if
(
!
strncasecmp
(
com
+
i
,
"force"
,
5
))
{
force_contig
=
true
;
force_contig
=
true
;
i
+=
5
;
i
+=
5
;
}
else
if
(
!
strncasecmp
(
com
+
i
,
"
proc
"
,
4
))
{
}
else
if
(
!
strncasecmp
(
com
+
i
,
"
virtual
"
,
7
))
{
co_proc
=
tru
e
;
co_proc
=
fals
e
;
i
+=
4
;
i
+=
7
;
}
else
if
(
i2
<
0
&&
(
com
[
i
]
<
58
&&
com
[
i
]
>
47
))
{
}
else
if
(
i2
<
0
&&
(
com
[
i
]
<
58
&&
com
[
i
]
>
47
))
{
i2
=
i
;
i2
=
i
;
i
++
;
i
++
;
...
@@ -392,6 +392,9 @@ static int _save_allocation(char *com, List allocated_partitions)
...
@@ -392,6 +392,9 @@ static int _save_allocation(char *com, List allocated_partitions)
char
filename
[
20
];
char
filename
[
20
];
char
save_string
[
255
];
char
save_string
[
255
];
FILE
*
file_ptr
;
FILE
*
file_ptr
;
char
*
co_proc
;
char
*
conn_type
;
ListIterator
results_i
;
ListIterator
results_i
;
memset
(
filename
,
0
,
20
);
memset
(
filename
,
0
,
20
);
...
@@ -413,13 +416,25 @@ static int _save_allocation(char *com, List allocated_partitions)
...
@@ -413,13 +416,25 @@ static int _save_allocation(char *com, List allocated_partitions)
}
}
file_ptr
=
fopen
(
filename
,
"w"
);
file_ptr
=
fopen
(
filename
,
"w"
);
if
(
file_ptr
!=
NULL
)
{
if
(
file_ptr
!=
NULL
)
{
fputs
(
"BlrtsImage=/bgl/BlueLight/ppcfloor/bglsys/bin/rts_hw.rts
\n
"
,
file_ptr
);
fputs
(
"LinuxImage=/bgl/BlueLight/ppcfloor/bglsys/bin/zImage.elf
\n
"
,
file_ptr
);
fputs
(
"MloaderImage=/bgl/BlueLight/ppcfloor/bglsys/bin/mmcs-mloader.rts
\n
"
,
file_ptr
);
fputs
(
"RamDiskImage=/bgl/BlueLight/ppcfloor/bglsys/bin/ramdisk.elf
\n
"
,
file_ptr
);
results_i
=
list_iterator_create
(
allocated_partitions
);
results_i
=
list_iterator_create
(
allocated_partitions
);
while
((
allocated_part
=
list_next
(
results_i
))
!=
NULL
)
{
while
((
allocated_part
=
list_next
(
results_i
))
!=
NULL
)
{
memset
(
save_string
,
0
,
255
);
memset
(
save_string
,
0
,
255
);
sprintf
(
save_string
,
"Nodes=bgl[%s] Type=%d Use=%d
\n
"
,
if
(
allocated_part
->
request
->
conn_type
==
TORUS
)
conn_type
=
"TORUS"
;
else
conn_type
=
"MESH"
;
if
(
allocated_part
->
request
->
co_proc
)
co_proc
=
"COPROCCESSOR"
;
else
co_proc
=
"VIRTUAL"
;
sprintf
(
save_string
,
"Nodes=bgl[%s] Type=%s Use=%s
\n
"
,
allocated_part
->
request
->
save_name
,
allocated_part
->
request
->
save_name
,
allocated_part
->
request
->
conn_type
,
conn_type
,
allocated_part
->
request
->
co_proc
);
co_proc
);
fputs
(
save_string
,
file_ptr
);
fputs
(
save_string
,
file_ptr
);
}
}
...
...
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