<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Recent changes to bugs</title><link>https://sourceforge.net/p/potrace/bugs/</link><description>Recent changes to bugs</description><atom:link href="https://sourceforge.net/p/potrace/bugs/feed.rss" rel="self"/><language>en</language><lastBuildDate>Mon, 16 Sep 2019 21:49:05 -0000</lastBuildDate><atom:link href="https://sourceforge.net/p/potrace/bugs/feed.rss" rel="self" type="application/rss+xml"/><item><title>#26 different results depending on compiler optimizations</title><link>https://sourceforge.net/p/potrace/bugs/26/?limit=50#78cd</link><description>&lt;div class="markdown_content"&gt;&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;status&lt;/strong&gt;: open --&amp;gt; closed&lt;/li&gt;
&lt;/ul&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Peter Selinger</dc:creator><pubDate>Mon, 16 Sep 2019 21:49:05 -0000</pubDate><guid isPermaLink="false">https://sourceforge.net0b8e823838c3fd75045c50e294addbc26aa24a7e</guid></item><item><title>#26 different results depending on compiler optimizations</title><link>https://sourceforge.net/p/potrace/bugs/26/?limit=25#00d5</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;Peter, thanks for the prompt reply and the helpful information. The patch indeed fixes the potrace tests. In the test suite of dvisvgm, I currently don't check the similarity of the shapes described by the generated paths but just the command sequences (moveto, curveto etc.) and its parameters as computed by &lt;code&gt;potrace_trace()&lt;/code&gt;. That's obviously too naive an approach. However, the issue has only ocurred since GCC 8. The generated paths now differ quite significantly between optimized and unoptimized code including the number of path segments. I guess I have to improve the tests a bit.&lt;br/&gt;
Thanks again for the helpful feedback.&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Martin Gieseking</dc:creator><pubDate>Mon, 16 Sep 2019 15:30:05 -0000</pubDate><guid isPermaLink="false">https://sourceforge.netfda8264a4dcf9de62784fe26ba9989ddb17d5934</guid></item><item><title>#26 different results depending on compiler optimizations</title><link>https://sourceforge.net/p/potrace/bugs/26/?limit=50#45f7</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;P.S.: another reason the tolerances must be adjusted from time to time is variations in Ghostscript. The test suite uses Ghostscript to render the traced files, and then compares the image to the expected output. Even small changes in Ghostscript's antialiasing routines can therefore require a recalibration of the test suite (not Potrace itself). It doesn't look like this was the problem in your user's case, but I thought I'd mention it since it does affect the reproducibility of the test suite.&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Peter Selinger</dc:creator><pubDate>Mon, 16 Sep 2019 13:40:25 -0000</pubDate><guid isPermaLink="false">https://sourceforge.net309ef06b1d77d227069a3fffba3a2b8bd5005e45</guid></item><item><title>#26 different results depending on compiler optimizations</title><link>https://sourceforge.net/p/potrace/bugs/26/?limit=50#7bab</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;Hi Martin,&lt;/p&gt;
&lt;p&gt;Potrace does use some floating point arithmetic, and due to rounding errors, the results can indeed depend on compiler optimizations (and presumably there might be a difference between 32-bit and 64-bit architectures as well, and between different compilers and OSs). One of the reasons is that processors internally use more than 64 bits to represent floating point numbers. Without compiler optimization, each intermediate result is converted to 64 bits, but with optimizations, the intermediate results are often left in a register with the additional precision. &lt;/p&gt;
&lt;p&gt;Gcc (but not clang) has an option -ffloat-store, which turns off this optimization, but it also slows Potrace down.&lt;/p&gt;
&lt;p&gt;These small variations are visually imperceptible and are considered as normal behavior for Potrace (i.e., not a bug). The checks in the test suite all have a tolerance built in. However, the tolerances must be fine-tuned from time to time, since compilers keep getting updated which can lead to tests falling just outside of the tolerances that previously worked.  The attached patch might fix the problem.&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Peter Selinger</dc:creator><pubDate>Mon, 16 Sep 2019 13:36:22 -0000</pubDate><guid isPermaLink="false">https://sourceforge.neteb9f035e19a73c127692fa37b833f3cfd8306e8b</guid></item><item><title>different results depending on compiler optimizations</title><link>https://sourceforge.net/p/potrace/bugs/26/</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;Hi Peter,&lt;/p&gt;
&lt;p&gt;I got a report from a user of dvisvgm saying that one of its test cases fail on 32-bit systems. It turned out that the reason for the failure is different path data created by potrace depending on whether the library was built with or without GCC compiler optimizations. The visual results are still fine, though. Is this "instability" of the results intended behavior and do you know if it can be avoided somehow? &lt;br/&gt;
So far, this behavior only ocurred on 32-bit systems.&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Martin Gieseking</dc:creator><pubDate>Mon, 16 Sep 2019 11:33:26 -0000</pubDate><guid isPermaLink="false">https://sourceforge.net95d8fdc6d6bd9f7d7d78f0523a7c64722be64260</guid></item><item><title>different results depending on compiler optimizations</title><link>https://sourceforge.net/p/potrace/bugs/26/</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;Ticket 26 has been modified: different results depending on compiler optimizations&lt;br/&gt;
Edited By: Peter Selinger (selinger)&lt;br/&gt;
Status updated: u'open' =&amp;gt; u'closed'&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Martin Gieseking</dc:creator><pubDate>Mon, 16 Sep 2019 11:33:26 -0000</pubDate><guid isPermaLink="false">https://sourceforge.net60676cdcce44b2045b58a2c52bfa74d83083647a</guid></item><item><title>#25 Too many &lt;/g&gt; markers in SVG output</title><link>https://sourceforge.net/p/potrace/bugs/25/?limit=50#ea73</link><description>&lt;div class="markdown_content"&gt;&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;status&lt;/strong&gt;: open --&amp;gt; closed&lt;/li&gt;
&lt;/ul&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Peter Selinger</dc:creator><pubDate>Wed, 17 Apr 2019 18:26:18 -0000</pubDate><guid isPermaLink="false">https://sourceforge.net1b8a37e53f0832b61b89f1159caf6a2c5412eb81</guid></item><item><title>#25 Too many &lt;/g&gt; markers in SVG output</title><link>https://sourceforge.net/p/potrace/bugs/25/?limit=50#740a</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;OK, great. Thanks for confirming. I will close the ticket. Please feel free to open another one if you should encounter this issue again. (By the way, you need to use the --opaque and --group options to get multiple &lt;code&gt;&amp;lt;g&amp;gt;&lt;/code&gt; tokens - this might help in replicating).&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Peter Selinger</dc:creator><pubDate>Wed, 17 Apr 2019 18:25:57 -0000</pubDate><guid isPermaLink="false">https://sourceforge.net2de325c89b4e794beff2177fb6cea06e2a833b83</guid></item><item><title>#25 Too many &lt;/g&gt; markers in SVG output</title><link>https://sourceforge.net/p/potrace/bugs/25/?limit=50#b61a</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;Thanks for reporting this, but I am not able to reproduce this problem. Could you please post the command line arguments you used, and attach the resulting SVG file?&lt;/p&gt;
&lt;p&gt;When I try to run a similar example, I get:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;1 token of the form &amp;lt;g stroke="..." transform="..." fill="..."&amp;gt;&amp;lt;/g&amp;gt;&lt;/li&gt;
&lt;li&gt;33 tokens of the form &amp;lt;g&amp;gt; without attributes&amp;lt;/g&amp;gt;&lt;/li&gt;
&lt;li&gt;34 tokens of the form &lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;This seems like correct SVG to me. -- Peter&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Peter Selinger</dc:creator><pubDate>Tue, 16 Apr 2019 12:14:22 -0000</pubDate><guid isPermaLink="false">https://sourceforge.net6b6e674f5328a0787abe60870dc93f6b2e2b8f78</guid></item><item><title>Too many &lt;/g&gt; markers in SVG output</title><link>https://sourceforge.net/p/potrace/bugs/25/</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;This problem may have already been resolved. Since I did not see any reports of this nature, I will describe it:&lt;/p&gt;
&lt;p&gt;I used potrace version 1.14 to create a SVG image file from a  ".ppm" image file. The resulting SVG file had 33 &amp;lt;g&amp;gt; tokens and 34 &amp;lt;/g&amp;gt; tokens. It is minor issue as the SVG file can be fixed with a text editor.&lt;/p&gt;
&lt;p&gt;The issue of an extra  token matters because importing the SVG file into FreeCAD causes a crash.&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">tkocou</dc:creator><pubDate>Tue, 16 Apr 2019 11:13:23 -0000</pubDate><guid isPermaLink="false">https://sourceforge.net4fda743b60a8a69fb123c17d5057158bce9c4be4</guid></item></channel></rss>