[Paraview] Program received signal SIGFPE, Arithmetic exception.

Burlen Loring burlen.loring at gmail.com
Mon Mar 20 14:31:28 EDT 2017


Hi Cory,

I had to apply to clang-format manually. it's up there now. changes were 
minimal so I squashed them into the patch. System has yet to acknowledge 
and re check. I assume it will eventually.

Try as I may the clang-format script you guys are using doesn't work for 
me.  here are the errors:
Fedora 24:

    smic:~/work/ParaView$Utilities/Scripts/clang-format.bash --amend
    YAML:4:24: error: invalid boolean
    AlignAfterOpenBracket: DontAlign
                            ^~~~~~~~~
    Error reading /home/bloring/work/ParaView/.clang-format: Invalid
    argument

Maybe this is due to clang-format --version == 3.7? not sure but I won't 
have time to re-install clang on this system, so I also tried on a newer 
system.

OSX Sierra:

    pipin:~/ParaView/ParaView$./Utilities/Scripts/clang-format.bash --amend
    sed: 1: "/: format\.clang-format ...": bad flag in substitute
    command: '}'
    xargs: illegal option -- d
    usage: xargs [-0opt] [-E eofstr] [-I replstr [-R replacements]] [-J
    replstr]
                  [-L number] [-n number [-x]] [-P maxprocs] [-s size]
                  [utility [argument ...]]

clang-format --version==4.0. what ended up working on the OSX system was

    clang-format -style="{BasedOnStyle: Mozilla, AlignAfterOpenBracket:
    DontAlign, AlignOperands: false, AlwaysBreakAfterReturnType: None,
    AlwaysBreakAfterDefinitionReturnType: None, BreakBeforeBraces:
    Allman, ColumnLimit: 100, Standard: Cpp03}" -i
    Qt/Components/pqPresetToPixmap.cxx

where style arguments were extracted from .clang-format in top level 
ParaView dir.

Burlen

On 03/17/2017 12:50 PM, Cory Quammen wrote:
> Burlen,
>
> Thanks for the patch.
>
> With regards to clang-format, we recently enabled automatic style
> enforcement checks. This way to fix is to install clang-format, run
> `git clang-format` in your ParaView source directory, amend your
> commit, then force push it with `git gitlab-push -f`.
>
> - Cory
>
> On Fri, Mar 17, 2017 at 3:36 PM, Burlen Loring <burlen.loring at gmail.com> wrote:
>> fyi, https://gitlab.kitware.com/paraview/paraview/merge_requests/1476
>>
>> it complains about clang-format, but it seems that the source file was not
>> formatted in that way to begin with.
>>
>>
>> On 03/17/2017 12:11 PM, Burlen Loring wrote:
>>> Thank you guys. I poked around this morning and found the following:
>>>
>>> The "BlueObeliskElements" is the only cmap in the default presets that
>>> triggers the issue. It has more values than can be displayed on a single
>>> line, and this is what triggers the FPE in the logic.
>>>
>>> Enforcing a minimum swatch size(terminology from the code) prevents the
>>> FPE and seems to produce the desired result of displaying all of the cmap
>>> values in one line, although they are quite small.
>>>
>>> a moment ago I pushed a patch onto gitlab demonstrating. Perhaps it or
>>> something like it could be back ported to the 5.3.0 branch?
>>>
>>> On 03/17/2017 07:09 AM, Cory Quammen wrote:
>>>> Burlen,
>>>>
>>>> I've created an issue for your report. It sure looks like a bug.
>>>>
>>>> https://gitlab.kitware.com/paraview/paraview/issues/17305
>>>>
>>>> Ufuk,
>>>>
>>>> That fix turns out to already be in v5.3.0:
>>>>
>>>> commit 90e710d5792116e640d25caa8ff455ae4e65d718
>>>> Author: Sergey Sindeev <ssindeev at yandex.ru>
>>>> Date:   Sun Dec 18 13:21:27 2016 +0100
>>>>
>>>>       fix a compilation crash when using the latest ICC compiler
>>>>
>>>> diff --git a/Qt/Components/pqPresetToPixmap.cxx
>>>> b/Qt/Components/pqPresetToPixmap.cxx
>>>> index 13f6b2e..b80fb80 100644
>>>> --- a/Qt/Components/pqPresetToPixmap.cxx
>>>> +++ b/Qt/Components/pqPresetToPixmap.cxx
>>>> @@ -254,15 +254,12 @@ QPixmap
>>>> pqPresetToPixmap::renderIndexedColorTransferFunction(
>>>>        // Now determine best value for Nh in [Nh/2,Nh-1]
>>>>        double bestQ = vtkMath::Inf();
>>>>        int best = -1;
>>>> -    for (int i = Nh / 2; i < Nh; ++i)
>>>> +    double ar = Nv * wmp / static_cast<double>(hmp * Nh);
>>>> +    double q = (ar >= 1.0) ? ar : 1. / ar;
>>>> +    if (q < bestQ)
>>>>        {
>>>> -      double ar = Nv * wmp / static_cast<double>(hmp * Nh);
>>>> -      double q = (ar >= 1.0) ? ar : 1. / ar;
>>>> -      if (q < bestQ)
>>>> -      {
>>>> -        bestQ = q;
>>>> -        best = i;
>>>> -      }
>>>> +      bestQ = q;
>>>> +      best = Nh-1;
>>>>        }
>>>>        Nh = best;
>>>>      }
>>>>
>>>> Thanks to you and Sergey for pursuing this Intel compiler issue and
>>>> ParaView issue!
>>>>
>>>> - Cory
>>>>
>>>> On Fri, Mar 17, 2017 at 3:18 AM, <u.utku.turuncoglu at be.itu.edu.tr> wrote:
>>>>> Hi Burlen,
>>>>>
>>>>> Your issue could be related with following,
>>>>>
>>>>> https://software.intel.com/en-us/forums/intel-c-compiler/topic/702934
>>>>>
>>>>> I opened a bug report in Intel form and they found a bug in that
>>>>> particular source file (pqPresetToPixmap.cxx). So, if you apply the fix
>>>>> you might solve the problem but i am not sure.
>>>>>
>>>>> I hope it helps,
>>>>> Regards,
>>>>>
>>>>> --ufuk
>>>>>
>>>>>
>>>>>> I tried out ParaView 5.3.0 today, and I encountered the above crash.
>>>>>>
>>>>>> steps to reproduce: load data (sphere source will work), set color by
>>>>>> var, open color map dialog, change to categorical, open choose presets
>>>>>> dialog, scroll down, when you get near the bottom you will get the
>>>>>> crash.
>>>>>>
>>>>>> Program received signal SIGFPE, Arithmetic exception.
>>>>>> 0x00007ffff660a833 in
>>>>>> pqPresetToPixmap::renderIndexedColorTransferFunction (this=0x5e22560,
>>>>>> stc=0x647f460, size=...) at
>>>>>> /home/bloring/work/ParaView/Qt/Components/pqPresetToPixmap.cxx:273
>>>>>> 273      Nh = wmp / (ss + PQ_SWATCH_PAD);
>>>>>> (gdb) p ss
>>>>>> $5 = -2
>>>>>>
>>>>>> of course PQ_SWATCH_PAD == 2
>>>>>> _______________________________________________
>>>>>> Powered by www.kitware.com
>>>>>>
>>>>>> Visit other Kitware open-source projects at
>>>>>> http://www.kitware.com/opensource/opensource.html
>>>>>>
>>>>>> Please keep messages on-topic and check the ParaView Wiki at:
>>>>>> http://paraview.org/Wiki/ParaView
>>>>>>
>>>>>> Search the list archives at: http://markmail.org/search/?q=ParaView
>>>>>>
>>>>>> Follow this link to subscribe/unsubscribe:
>>>>>> http://public.kitware.com/mailman/listinfo/paraview
>>>>>>
>>>>> _______________________________________________
>>>>> Powered by www.kitware.com
>>>>>
>>>>> Visit other Kitware open-source projects at
>>>>> http://www.kitware.com/opensource/opensource.html
>>>>>
>>>>> Please keep messages on-topic and check the ParaView Wiki at:
>>>>> http://paraview.org/Wiki/ParaView
>>>>>
>>>>> Search the list archives at: http://markmail.org/search/?q=ParaView
>>>>>
>>>>> Follow this link to subscribe/unsubscribe:
>>>>> http://public.kitware.com/mailman/listinfo/paraview
>>>>
>>>>
>
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/paraview/attachments/20170320/587cb0e6/attachment.html>


More information about the ParaView mailing list