Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
GPU Accelerated Tree Search Chapel
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
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
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
UltraBO
GPU Accelerated Tree Search Chapel
Commits
6838fc5d
Commit
6838fc5d
authored
10 months ago
by
Guillaume-Helbecque
Browse files
Options
Downloads
Patches
Plain Diff
declare lbounds inside pfsp_search
parent
3953bbd8
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
pfsp_gpu_chpl.chpl
+21
-21
21 additions, 21 deletions
pfsp_gpu_chpl.chpl
with
21 additions
and
21 deletions
pfsp_gpu_chpl.chpl
+
21
−
21
View file @
6838fc5d
...
...
@@ -26,15 +26,6 @@ config const inst: int = 14; // instance
const jobs = taillard_get_nb_jobs(inst);
const machines = taillard_get_nb_machines(inst);
var lbound1 = new WrapperLB1(jobs, machines); //lb1_bound_data(jobs, machines);
taillard_get_processing_times(lbound1!.lb1_bound.p_times, inst);
fill_min_heads_tails(lbound1!.lb1_bound);
var lbound2 = new WrapperLB2(jobs, machines);
fill_machine_pairs(lbound2!.lb2_bound/*, LB2_FULL*/);
fill_lags(lbound1!.lb1_bound.p_times, lbound2!.lb2_bound);
fill_johnson_schedules(lbound1!.lb1_bound.p_times, lbound2!.lb2_bound);
const initUB = taillard_get_best_ub(inst);
proc check_parameters()
...
...
@@ -70,7 +61,7 @@ proc print_results(const optimum: int, const exploredTree: uint, const exploredS
writeln("=================================================\n");
}
proc decompose_lb2(const parent: Node, ref tree_loc: uint, ref num_sol: uint,
proc decompose_lb2(const
ref lbound1, const ref lbound2, const
parent: Node, ref tree_loc: uint, ref num_sol: uint,
ref best: int, ref pool: SinglePool(Node))
{
for i in parent.limit1+1..(jobs-1) {
...
...
@@ -80,7 +71,7 @@ proc decompose_lb2(const parent: Node, ref tree_loc: uint, ref num_sol: uint,
child.prmu = parent.prmu;
child.prmu[parent.depth] <=> child.prmu[i];
var lowerbound = lb2_bound(lbound1
!.lb1_bound, lbound2!.lb2_bound
, child.prmu, child.limit1, jobs, best);
var lowerbound = lb2_bound(lbound1
, lbound2
, child.prmu, child.limit1, jobs, best);
if (child.depth == jobs) { // if child leaf
num_sol += 1;
...
...
@@ -146,12 +137,21 @@ proc pfsp_search(ref optimum: int, ref exploredTree: uint, ref exploredSol: uint
*/
timer.start();
var lbound1 = new lb1_bound_data(jobs, machines);
taillard_get_processing_times(lbound1.p_times, inst);
fill_min_heads_tails(lbound1);
var lbound2 = new lb2_bound_data(jobs, machines);
fill_machine_pairs(lbound2/*, LB2_FULL*/);
fill_lags(lbound1.p_times, lbound2);
fill_johnson_schedules(lbound1.p_times, lbound2);
while (pool.size < 10000) {
var hasWork = 0;
var parent = pool.popFront(hasWork);
if !hasWork then break;
decompose_lb2(parent, exploredTree, exploredSol, best, pool);
decompose_lb2(
lbound1, lbound2,
parent, exploredTree, exploredSol, best, pool);
}
timer.stop();
const res1 = (timer.elapsed(), exploredTree, exploredSol);
...
...
@@ -169,22 +169,22 @@ proc pfsp_search(ref optimum: int, ref exploredTree: uint, ref exploredSol: uint
var parents: [0..#M] Node = noinit;
var bounds: [0..#(M*jobs)] int(32) = noinit;
var lbound1_d:
lbound1.type
;
var lbound2_d:
lbound2.type
;
var lbound1_d:
WrapperLB1
;
var lbound2_d:
WrapperLB2
;
var parents_d: WrapperArrayParents;
var bounds_d: WrapperArrayBounds;
on device {
lbound1_d = new WrapperLB1(jobs, machines);
lbound1_d!.lb1_bound.p_times = lbound1
!.lb1_bound
.p_times;
lbound1_d!.lb1_bound.min_heads = lbound1
!.lb1_bound
.min_heads;
lbound1_d!.lb1_bound.min_tails = lbound1
!.lb1_bound
.min_tails;
lbound1_d!.lb1_bound.p_times = lbound1.p_times;
lbound1_d!.lb1_bound.min_heads = lbound1.min_heads;
lbound1_d!.lb1_bound.min_tails = lbound1.min_tails;
lbound2_d = new WrapperLB2(jobs, machines);
lbound2_d!.lb2_bound.johnson_schedules = lbound2
!.lb2_bound
.johnson_schedules;
lbound2_d!.lb2_bound.lags = lbound2
!.lb2_bound
.lags;
lbound2_d!.lb2_bound.machine_pairs = lbound2
!.lb2_bound
.machine_pairs;
lbound2_d!.lb2_bound.machine_pair_order = lbound2
!.lb2_bound
.machine_pair_order;
lbound2_d!.lb2_bound.johnson_schedules = lbound2.johnson_schedules;
lbound2_d!.lb2_bound.lags = lbound2.lags;
lbound2_d!.lb2_bound.machine_pairs = lbound2.machine_pairs;
lbound2_d!.lb2_bound.machine_pair_order = lbound2.machine_pair_order;
parents_d = new WrapperArrayParents();
bounds_d = new WrapperArrayBounds();
...
...
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