Skip to content

Commit

Permalink
Merge pull request #2173 from deslaughter/b/MAP_free_outlist_crash
Browse files Browse the repository at this point in the history
Fix crash in MAP_End when using Intel's new icx compiler and disable caching in setup-python GH action
  • Loading branch information
andrew-platt authored Apr 24, 2024
2 parents 6a7a543 + 0f08226 commit 2510bc2
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 26 deletions.
36 changes: 18 additions & 18 deletions .github/workflows/automated-dev-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
# cache: 'pip'
- name: Install dependencies
run: |
pip install -r requirements.txt
Expand Down Expand Up @@ -128,7 +128,7 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
# cache: 'pip'
- name: Install dependencies
run: |
pip install -r requirements.txt
Expand Down Expand Up @@ -173,7 +173,7 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
# cache: 'pip'
- name: Install dependencies
run: |
pip install -r requirements.txt
Expand Down Expand Up @@ -226,7 +226,7 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
# cache: 'pip'
- name: Install dependencies
run: |
pip install -r requirements.txt
Expand Down Expand Up @@ -263,7 +263,7 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
# cache: 'pip'
- name: Install dependencies
run: |
pip install -r requirements.txt
Expand Down Expand Up @@ -300,7 +300,7 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
# cache: 'pip'
- name: Install dependencies
run: |
pip install -r requirements.txt
Expand Down Expand Up @@ -339,7 +339,7 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
# cache: 'pip'
- name: Install dependencies
run: |
pip install -r requirements.txt
Expand Down Expand Up @@ -400,7 +400,7 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
# cache: 'pip'
- name: Install dependencies
run: |
pip install -r requirements.txt
Expand Down Expand Up @@ -455,7 +455,7 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
# cache: 'pip'
- name: Install dependencies
run: |
pip install -r requirements.txt
Expand Down Expand Up @@ -513,7 +513,7 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
# cache: 'pip'
- name: Install dependencies
run: |
pip install -r requirements.txt
Expand Down Expand Up @@ -560,7 +560,7 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
# cache: 'pip'
- name: Install dependencies
run: |
pip install -r requirements.txt
Expand Down Expand Up @@ -612,7 +612,7 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
# cache: 'pip'
- name: Install dependencies
run: |
pip install -r requirements.txt
Expand Down Expand Up @@ -661,7 +661,7 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
# cache: 'pip'
- name: Install dependencies
run: |
pip install -r requirements.txt
Expand Down Expand Up @@ -710,7 +710,7 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
# cache: 'pip'
- name: Install dependencies
run: |
pip install -r requirements.txt
Expand Down Expand Up @@ -759,7 +759,7 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
# cache: 'pip'
- name: Install dependencies
run: |
pip install -r requirements.txt
Expand Down Expand Up @@ -808,7 +808,7 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
# cache: 'pip'
- name: Install dependencies
run: |
pip install -r requirements.txt
Expand Down Expand Up @@ -857,7 +857,7 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
# cache: 'pip'
- name: Install dependencies
run: |
pip install -r requirements.txt
Expand Down Expand Up @@ -906,7 +906,7 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
# cache: 'pip'
- name: Install dependencies
run: |
pip install -r requirements.txt
Expand Down
24 changes: 16 additions & 8 deletions modules/map/src/mapinit.c
Original file line number Diff line number Diff line change
Expand Up @@ -2304,7 +2304,14 @@ MAP_ERROR_CODE push_variable_to_output_list(OutputList* y_list, const int i, dou
size = list_size(&y_list->out_list_ptr);
iter_vartype = (VarTypePtr*)list_get_at(&y_list->out_list_ptr, size-1);
iter_vartype->value = variable_ref;
iter_vartype->name = bformat("%s[%d]", alias, i);
if (i >= 0)
{
iter_vartype->name = bformat("%s[%d]", alias, i);
}
else
{
iter_vartype->name = bformat(alias);
}
iter_vartype->units = bformat("%s", units);

return MAP_SAFE;
Expand All @@ -2325,49 +2332,50 @@ MAP_ERROR_CODE set_output_list(Domain* domain, MAP_InitOutputType_t* io_type, ch
line_iter = (Line*)list_iterator_next(&domain->line);

if (line_iter->options.gx_anchor_pos_flag) {
list_append(&y_list->out_list_ptr, &line_iter->anchor->position_ptr.x);
success = push_variable_to_output_list(y_list, -1, line_iter->anchor->position_ptr.x.value, line_iter->anchor->position_ptr.x.name->data, line_iter->anchor->position_ptr.x.units->data);
io_type->writeOutputHdr_Len++;
io_type->writeOutputUnt_Len++;
};

if (line_iter->options.gy_anchor_pos_flag) {
list_append(&y_list->out_list_ptr, &line_iter->anchor->position_ptr.y);
success = push_variable_to_output_list(y_list, -1, line_iter->anchor->position_ptr.x.value, line_iter->anchor->position_ptr.x.name->data, line_iter->anchor->position_ptr.x.units->data);
io_type->writeOutputHdr_Len++;
io_type->writeOutputUnt_Len++;
};

if (line_iter->options.gz_anchor_pos_flag) {
list_append(&y_list->out_list_ptr, &line_iter->anchor->position_ptr.z);
success = push_variable_to_output_list(y_list, -1, line_iter->anchor->position_ptr.x.value, line_iter->anchor->position_ptr.x.name->data, line_iter->anchor->position_ptr.x.units->data);
io_type->writeOutputHdr_Len++;
io_type->writeOutputUnt_Len++;
};

if (line_iter->options.gx_pos_flag) {
list_append(&y_list->out_list_ptr, &line_iter->fairlead->position_ptr.x);
success = push_variable_to_output_list(y_list, -1, line_iter->fairlead->position_ptr.x.value, line_iter->fairlead->position_ptr.x.name->data, line_iter->fairlead->position_ptr.x.units->data);
io_type->writeOutputHdr_Len++;
io_type->writeOutputUnt_Len++;
};

if (line_iter->options.gy_pos_flag) {
list_append(&y_list->out_list_ptr, &line_iter->fairlead->position_ptr.y);
success = push_variable_to_output_list(y_list, -1, line_iter->fairlead->position_ptr.y.value, line_iter->fairlead->position_ptr.y.name->data, line_iter->fairlead->position_ptr.y.units->data);
io_type->writeOutputHdr_Len++;
io_type->writeOutputUnt_Len++;
};

if (line_iter->options.gz_pos_flag) {
list_append(&y_list->out_list_ptr, &line_iter->fairlead->position_ptr.z);
success = push_variable_to_output_list(y_list, -1, line_iter->fairlead->position_ptr.z.value, line_iter->fairlead->position_ptr.z.name->data, line_iter->fairlead->position_ptr.z.units->data);
io_type->writeOutputHdr_Len++;
io_type->writeOutputUnt_Len++;
};

if (line_iter->options.H_flag) {
list_append(&y_list->out_list_ptr, &line_iter->H);
success = push_variable_to_output_list(y_list, -1, line_iter->H.value, line_iter->H.name->data, line_iter->H.units->data);
io_type->writeOutputHdr_Len++;
io_type->writeOutputUnt_Len++;
};

if (line_iter->options.V_flag) {
list_append(&y_list->out_list_ptr, &line_iter->V);
success = push_variable_to_output_list(y_list, -1, line_iter->V.value, line_iter->V.name->data, line_iter->V.units->data);
io_type->writeOutputHdr_Len++;
io_type->writeOutputUnt_Len++;
};
Expand Down

0 comments on commit 2510bc2

Please sign in to comment.