Heads up: I-pipe patch status on ARM
Hi,
Short version: good news, we are able to compile a Linux 3.4 "all-in-one kernel" with Xenomai support.
Long version:
As you may know, the direction followed by the Linux kernel on ARM is to allow, as much as possible, to compile a single kernel to run on many ARM SOCs. This basically means the systematic elimination of SOC-specific piece of codes which were chosen at compilation time. Historically, Xenomai SOC support code fell into that category, with everything SOC specific being called __ipipe_mach_something, and being selected at compilation time, this was not a bad choice at the time it was made: Linux kernel code was not able to be compiled for several SOCs at a time anyway.
Changing this started with the I-pipe patch for Linux 2.6.33, with the implementation of the "kuser" tsc emulation, whose side effect was to make the tsc emulation registered at run-time. The tsc emulation code is provided in the "vector page", at the same place as other helpers provided by the Linux kernel (the ARM user-space atomic_cmpxchg is implemented this way for instance). The aim of putting the helper there is to avoid having to compile a SOC specific code in user-space. This has been exploited by Xenomai 2.6.0 which removed the --enable-arm-mach option and uses the "kuser" helper by default (but allows to fallback to the old way in order to remain compatible with old patches). This allows, for instance, a Debian "xenomai-runtime" package which runs with any SOC, whatever the implementation of their tsc. Incidentally, tests have also showed that implementing the tsc emulation code that way, actually reduced the average tsc latency despite the fact that reading the tsc is a function call and no longer a piece of inlined C code, that is probably because the helpers are implemented in assembly. To the point where the latency of the (software) tsc is lower on a Cortex A9 based processor than the (hardware) tsc on an Intel Atom 230.
The I-pipe core patch for Linux 3.2 provided another occasion to move in the same direction:
- the I-pipe timer factorization effort allowed to get the hardware timer support code registered at run-time and no longer hard-coded at compilation time. Again, this was not the original aim, the aim was to have a hardware timer support uniform across all architectures to reduce the Xenomai arch-specific cruft, and a secondary aim on ARM was to allow sharing more code with the clockevent infrastructure, by simply reusing the clockevent timer call-backs when the hardware timer is shared between Xenomai and Linux. It turns out that we also reused the clockevent call-backs on other architectures, and in fact, it also simplified compiling a Linux kernel on x86, because we no longer need a kernel compiled differently to use the local APIC timer or the PIT timer.
- we also get the PIC muting functions on ARM to be registered at run-time, this time on purpose.
While writing a documentation on how to port the I-pipe core patch to a new ARM board [1], I realized that we still had some "__ipipe_mach" code in the I-pipe core patch: the IPI handling code on SMP systems.
So, I took the chance of working on the I-pipe patch for Linux 3.4 to remedy this situation. The idea is simple: in the Linux kernel on ARM the IPIs live in a different numbering space as the IRQs, but the interrupt pipeline wants to mix them with irqs, to have a common pipeline for both types of interrupts. Some __ipipe_mach macros made that work. For instance, on Cortex A9, the IPIs are actually in the same numbering space as the IRQs at the interrupt controller level, they simply are irqs from 2 to 16, so, in the I-pipe patch before Linux 3.4, we simply used the hardware IPI numbers as irq numbers. But this has two disadvantages:
- starting with Linux 3.4, hardware irq numbers are remapped to Linux virtual irq numbers, with the advent of "irq domains", so the fact that there is room for the IPIs is no longer guaranteed;
- more importantly, on a cortex A9 kernel, this means that Linux domain irq handlers for irqs 2 to 16 were redirecting these irqs to Linux IPI handler, which is the wrong thing to do on non cortex A9 processor. So, the cure was to systematically remap the IPIs to I-pipe virqs, (and remove the __ipipe_mach macros), this does not change anything with regard to the path followed for handling IPIs except for the particular number they use along the interrupt pipeline, but this avoids the two issues mentioned above:
- however Linux irqs are remapped, they do not conflict with I-pipe virqs
- a cortex A9 enabled kernel running on another SOC (a uniprocessor SOC for instance), reserve virqs for IPIs which are simply never used, the other SOC irqs are handled as irqs, as should be.
So, the net result of all this is that I have been able to run a Linux kernel compiled with Xenomai support both for OMAP3 and OMAP4 at the same time, both on an OMAP3 and on OMAP4, and to compile test a Xenomai kernel for the two imx_v4_v4_defconfig and imx_v6_v7 kernel configurations which cover about every Freescale IMX processors around (including the cortex A9 based IMX6Q).
Whether the multi-SOC feature will really be used by Xenomai users on ARM remains to be seen (but why not a Debian kernel or two with all ARM marchines around?), but in any case, it is a net win for simply compile testing the I-pipe patch on ARM. The only remaining problem is with AT91s, which still have to be compiled separately on Linux 3.4, but I see the 3.5 kernel allows compiling them all at once.
The bad news is that in order to achieve the goal of a kernel runnable on multiple SOC, the Linux kernel has increased the path followed to handle hardware interrupts (notably with CONFIG_MULTI_IRQ_HANDLER, irq domains), and that is probably the reason why we get slightly worse latencies with Xenomai for Linux 3.4 on ARM [2].
[1] http://www.xenomai.org/index.php/I-pipe-core:ArmPorting
[2] http://sisyphus.hd.free.fr/~gilles/core-3.4-latencies/
Signature · 1 line
Gilles.
Thanks for the timely update Gilles - Just finished work on an (unsupported) ARM1176 SoC running at 700MHz and the documents came in handy. Only a rough draft at the moment and some of the kernel options need tuning, but as a starting point, it looks quite reasonable.
Running a 3.2.21 kernel and Xenomai-2.6.1, graphed the latency test over a 60 minute run. Look forward to testing a 3.4 series kernel to see if the results can be improved upon.
Regards, Paul.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: latency-t0.png
Type: image/png
Size: 5702 bytes
Desc: not available
URL: <http://www.xenomai.org/pipermail/xenomai/attachments/20120728/b789c62a/attachment.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: latency-t1.png
Type: image/png
Size: 5423 bytes
Desc: not available
URL: <http://www.xenomai.org/pipermail/xenomai/attachments/20120728/b789c62a/attachment-0001.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: latency-t2.png
Type: image/png
Size: 5224 bytes
Desc: not available
URL: <http://www.xenomai.org/pipermail/xenomai/attachments/20120728/b789c62a/attachment-0002.png>
Quoted 8 lines · Paul
Thanks for the timely update Gilles - Just finished work on an (unsupported) ARM1176 SoC running at 700MHz and the documents came in handy. Only a rough draft at the moment and some of the kernel options need tuning, but as a starting point, it looks quite reasonable.
Running a 3.2.21 kernel and Xenomai-2.6.1, graphed the latency test over a 60 minute run.
It does not look that bad. However, "dohell 3600" does not do much. If you want to improve the latencies, use "-p 100" instead of "-p 1000" ;-)
How do you get the fancy grid with gnuplot? We could add the option to scripts/histo.gp. Note that I prefer to draw graphs with a log scale, I find they are more meanningful, otherwise, you do not really see how the graph ends.
Quoted 3 lines
Look forward to testing a 3.4 series kernel to see if
the results can be improved upon.
I am running some tests on omap3 and omap4, so far with not much success. My next try will be to simply disable CONFIG_MULTI_IRQ_HANDLER and the irq domains, to see if I can get the same latencies as 3.2
Quoted 31 lines
Regards, Paul.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: latency-t0.png
Type: image/png
Size: 5702 bytes
Desc: not available
URL: <http://www.xenomai.org/pipermail/xenomai/attachments/20120728/b789c62a/attachment.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: latency-t1.png
Type: image/png
Size: 5423 bytes
Desc: not available
URL: <http://www.xenomai.org/pipermail/xenomai/attachments/20120728/b789c62a/attachment-0001.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: latency-t2.png
Type: image/png
Size: 5224 bytes
Desc: not available
URL: <http://www.xenomai.org/pipermail/xenomai/attachments/20120728/b789c62a/attachment-0002.png>
_______________________________________________
Xenomai mailing list
[email protected]
http://www.xenomai.org/mailman/listinfo/xenomai
Signature · 1 line
Gilles.
Quoted 3 lines · Gilles Chanteperdrix
It does not look that bad. However, "dohell 3600" does not do much. If you want to improve the latencies, use "-p 100" instead of "-p 1000" ;-)
Could try running a 'make j8 Image' in the kernel source tree. That would give the system a good run for my money.. However, dohell gives a baseline load that others could repeat (my excuse, and I'm sticking to it ;-p )
Quoted 4 lines
How do you get the fancy grid with gnuplot? We could add the option to
scripts/histo.gp. Note that I prefer to draw graphs with a log scale, I find they are more meaningful, otherwise, you do not really see how the graph ends.
gnuplot> set grid
The next set of plots, I'll use a log scale as you suggest.
Regards, Paul.
Quoted 1 line · Paul
However, "dohell 3600" does not do much.
try :
dohell -all
;)
Quoted 6 lines · xenophile
Quoted 1 line · Paul
However, "dohell 3600" does not do much.
try :
dohell -all
We follow POSIX guidelines for command line options, so that would be dohell --all.
The reason why there is no dohell --all is that all dohell options require arguments, such as the network address of a server, the path to ltp, the path to hackbench, the path of a block device mount point.
Signature · 1 line
Gilles.
Quoted 7 lines · Gilles Chanteperdrix
Quoted 5 lines · xenophile
Quoted 1 line · Paul
However, "dohell 3600" does not do much.
try :
Quoted 9 lines
Quoted 1 line
dohell -all
We follow POSIX guidelines for command line options, so that would be dohell --all.
The reason why there is no dohell --all is that all dohell options require arguments, such as the network address of a server, the path to ltp, the path to hackbench, the path of a block device mount point.
Sorry , that was a little humour that may be lost on non anglophone readers.
"hell all" is slang like "sod all" or "que dalle "
You are of course correct , it should have read dohell --all ;)
Quoted 9 lines · Paul
Quoted 3 lines · Gilles Chanteperdrix
It does not look that bad. However, "dohell 3600" does not do much. If you want to improve the latencies, use "-p 100" instead of "-p 1000" ;-)
Could try running a 'make j8 Image' in the kernel source tree. That would give the system a good run for my money.. However, dohell gives a baseline load that others could repeat (my excuse, and I'm sticking to it ;-p )
I agree, that is the reason we provide dohell. But what I meant is that you should use the various options to add some load (-s adds network trafic, -m adds some I/O, -l runs the whole LTP testsuite, which gives the kernel the opportunity to try and perturb xenomai with many differents paths in its code, and many different kinds of workload).
Quoted 9 lines
Quoted 5 lines
How do you get the fancy grid with gnuplot? We could add the option to
scripts/histo.gp. Note that I prefer to draw graphs with a log scale, I find they are more meaningful, otherwise, you do not really see how the graph ends.gnuplot> set grid
The next set of plots, I'll use a log scale as you suggest.
We have been talking about this, but it would be nice to have a database somewhere with the results of a latency runs (the file generated by latency -g for instance), with some data attached (anything from a simple free from string, to a complete database record with fields such as linux version, I-pipe version, xenomai version, dohell command line), and have a way to generate graphs from several such records. I guess this could be done with a web application, using svg to avoid generating the graphs on the server.
Signature · 1 line
Gilles.
Quoted 10 lines · Paul
Quoted 4 lines
Quoted 4 lines
How do you get the fancy grid with gnuplot? We could add the option to
scripts/histo.gp. Note that I prefer to draw graphs with a log scale, I find they are more meaningful, otherwise, you do not really see how the graph ends.gnuplot> set grid
The next set of plots, I'll use a log scale as you suggest.
Regards, Paul.
current gnuplot has good support for svg, scalable graphics. The "standalone" option when setting svg terminal makes an autonomous svg file with some nice interactive features like:
clicking on legend to toggle lines' visibility and a button to toggle the grid on/off; mouseover cursor coordinate readout; and of course you can zoom in without it becoming a pixel blur.
Depending on the number of points plotted it can be quite compact. Also the gzip compressed format .svgz can be displayed directly or embedded in competent browsers like Firefox/Opera/Safari.
bitmap rendered graphs should be a relic of the 1990's ;)
Quoted 1 line · xenophile
bitmap rendered graphs should be a relic of the 1990's ;)
On the other hand, a bitmap is rendered once and only once, which really makes sense for a static page, will appear the same in all navigators, including those which do not support svg.
Signature · 1 line
Gilles.
Quoted 9 lines · Gilles Chanteperdrix
Quoted 1 line · xenophile
bitmap rendered graphs should be a relic of the 1990's ;)
On the other hand, a bitmap is rendered once and only once, which really makes sense for a static page, will appear the same in all navigators, including those which do not support svg.
How often it is rendered depends upon the viewer. I don't see how this relates to whether the page is "static". (I'm assuming you are talking about static vs dyanamic content at the server end).
I don't see any fundamental difference in whether you _create_ (as opposed to render) a graphic in svg , png or jpeg.
There is nothing about svg/svgz that means you have to create it on the fly each time you serve a page. It is an XML format but as I said it can be embedded (hence the svg part can be pre-made).
I do this on a 200MHz embedded ARM system running lighttpd. The pseudo real-time output is created in svg every 15min or on demand. The surrounding html template is static.
Gnuplot runs on the ARM.
Quoted 18 lines · xenophile
Quoted 9 lines · Gilles Chanteperdrix
Quoted 1 line · xenophile
bitmap rendered graphs should be a relic of the 1990's ;)
On the other hand, a bitmap is rendered once and only once, which really makes sense for a static page, will appear the same in all navigators, including those which do not support svg.
How often it is rendered depends upon the viewer. I don't see how this relates to whether the page is "static". (I'm assuming you are talking about static vs dyanamic content at the server end).
I don't see any fundamental difference in whether you _create_ (as opposed to render) a graphic in svg , png or jpeg.
Quoted 7 lines
There is nothing about svg/svgz that means you have to create it on the fly each time you serve a page. It is an XML format but as I said it can be embedded (hence the svg part can be pre-made).
I do this on a 200MHz embedded ARM system running lighttpd. The pseudo real-time output is created in svg every 15min or on demand. The surrounding html template is static.
As far as I understand, the rendering (I am talking about the graphical rendering) is done by every client which wants to view the graph, which is stupid if it is always the same graph (that is what I meant by static). And has a number of issue.
I do not understand why you do not want to do the rendering on a 200 MHz ARM, but if the machine serving the page is powerful enough, and the graph not updated frequently, I find it makes a lot of sense to do the rendering only once.
Quoted 1 line
Gnuplot runs on the ARM.
I do not discuss the fact that getting gnuplot to generate an svg will consume less power. But overall, it will get all viewer to consume power to do the rendering, which the static bitmap file avoids.
Signature · 1 line
Gilles.
Quoted 39 lines · Gilles Chanteperdrix
Quoted 18 lines · xenophile
Quoted 9 lines · Gilles Chanteperdrix
Quoted 1 line · xenophile
bitmap rendered graphs should be a relic of the 1990's ;)
On the other hand, a bitmap is rendered once and only once, which really makes sense for a static page, will appear the same in all navigators, including those which do not support svg.
How often it is rendered depends upon the viewer. I don't see how this relates to whether the page is "static". (I'm assuming you are talking about static vs dyanamic content at the server end).
I don't see any fundamental difference in whether you _create_ (as opposed to render) a graphic in svg , png or jpeg.
Quoted 7 lines
There is nothing about svg/svgz that means you have to create it on the fly each time you serve a page. It is an XML format but as I said it can be embedded (hence the svg part can be pre-made).
I do this on a 200MHz embedded ARM system running lighttpd. The pseudo real-time output is created in svg every 15min or on demand. The surrounding html template is static.
As far as I understand, the rendering (I am talking about the graphical rendering) is done by every client which wants to view the graph, which is stupid if it is always the same graph (that is what I meant by static). And has a number of issue.
I do not understand why you do not want to do the rendering on a 200 MHz ARM, but if the machine serving the page is powerful enough, and the graph not updated frequently, I find it makes a lot of sense to do the rendering only once.
Quoted 6 lines
Quoted 1 line
Gnuplot runs on the ARM.
I do not discuss the fact that getting gnuplot to generate an svg will consume less power. But overall, it will get all viewer to consume power to do the rendering, which the static bitmap file avoids.
The whole point of SVG is the S: scalable. If you "render" it to a bitmap on the server no one scale it in their viewer (web browser in this case).
Now whether decoding png or jpeg compression of an image (including much blank white area) and then interpolating to the final screen rendered size raster image in the users browser is more or less "power efficient" that sending a textual vector description that the viewer draws line by line I have no idea.
Since the PC is probably consuming about 150W just sitting there I'm not sure what the point aiming for is.
SVG, basically gives the browser and the user total freedom of what size to scale the output. rather than sending a series of dots which have a predetermined resolution.
My reason for using SVG on the ARM is not save power or because it could not handle producing a png , it is to give the viewer of the graphic the ability to zoom in to any desired level and benefit from things like toggling off lines that obscure the one he's interested in and getting cursor readout of data points on the graph.
No way is that sort of thing possible with png.
I don't quite think you are appreciating all the differences between vectorial and bitmap formats. Hopefully, I've explained some of our confusion over the term "render". The image is only rendered in the viewer, Both vector and bitmap are descriptions of what has to be rendered.
regards
Quoted 51 lines · xenophile
Quoted 39 lines · Gilles Chanteperdrix
Quoted 18 lines · xenophile
Quoted 9 lines · Gilles Chanteperdrix
Quoted 1 line · xenophile
bitmap rendered graphs should be a relic of the 1990's ;)
On the other hand, a bitmap is rendered once and only once, which really makes sense for a static page, will appear the same in all navigators, including those which do not support svg.
How often it is rendered depends upon the viewer. I don't see how this relates to whether the page is "static". (I'm assuming you are talking about static vs dyanamic content at the server end).
I don't see any fundamental difference in whether you _create_ (as opposed to render) a graphic in svg , png or jpeg.
Quoted 7 lines
There is nothing about svg/svgz that means you have to create it on the fly each time you serve a page. It is an XML format but as I said it can be embedded (hence the svg part can be pre-made).
I do this on a 200MHz embedded ARM system running lighttpd. The pseudo real-time output is created in svg every 15min or on demand. The surrounding html template is static.
As far as I understand, the rendering (I am talking about the graphical rendering) is done by every client which wants to view the graph, which is stupid if it is always the same graph (that is what I meant by static). And has a number of issue.
I do not understand why you do not want to do the rendering on a 200 MHz ARM, but if the machine serving the page is powerful enough, and the graph not updated frequently, I find it makes a lot of sense to do the rendering only once.
Quoted 6 lines
Quoted 1 line
Gnuplot runs on the ARM.
I do not discuss the fact that getting gnuplot to generate an svg will consume less power. But overall, it will get all viewer to consume power to do the rendering, which the static bitmap file avoids.
The whole point of SVG is the S: scalable. If you "render" it to a bitmap on the server no one scale it in their viewer (web browser in this case).
Quoted 8 lines
Now whether decoding png or jpeg compression of an image (including much blank white area) and then interpolating to the final screen rendered size raster image in the users browser is more or less "power efficient" that sending a textual vector description that the viewer draws line by line I have no idea.
Since the PC is probably consuming about 150W just sitting there I'm not sure what the point aiming for is.
I mean "processing power". Intuitively, generating a text file after reading points from other text files seems more economic, than drawing the lines to a bitmap in memory, rendering the text, and compressing with png. But you are right, this is not even obvious.
Quoted 11 lines
SVG, basically gives the browser and the user total freedom of what size to scale the output. rather than sending a series of dots which have a predetermined resolution.
My reason for using SVG on the ARM is not save power or because it could not handle producing a png , it is to give the viewer of the graphic the ability to zoom in to any desired level and benefit from things like toggling off lines that obscure the one he's interested in and getting cursor readout of data points on the graph.
Quoted 6 lines
No way is that sort of thing possible with png.
I don't quite think you are appreciating all the differences between vectorial and bitmap formats. Hopefully, I've explained some of our confusion over the term "render". The image is only rendered in the viewer, Both vector and bitmap are descriptions of what has to be rendered.
Ok, ok, I am convinced, you can send the patch, now.
Signature · 1 line
Gilles.
Quoted 1 line · xenophile
bitmap rendered graphs should be a relic of the 1990's ;)
... but still look much better without getting to much in gnuplot configuration:
http://sisyphus.hd.free.fr/~gilles/core-3.4-latencies/atom.png
http://sisyphus.hd.free.fr/~gilles/core-3.4-latencies/atom.svg
Signature · 1 line
Gilles.
Quoted 10 lines · Gilles Chanteperdrix
Quoted 1 line · xenophile
bitmap rendered graphs should be a relic of the 1990's ;)
... but still look much better without getting to much in gnuplot configuration:
http://sisyphus.hd.free.fr/~gilles/core-3.4-latencies/atom.png
http://sisyphus.hd.free.fr/~gilles/core-3.4-latencies/atom.svg
There is a problem with the legend not showing for some reason. If you'd like to send me your gnuplot script and a sample data file I could look what is going wrong. (Off list if you prefer).
You may want to explicitly specify the font size as well since it seems you prefer the smaller text in the png.
Apart from fixing the problem with the legend , where's the "much better"?
Your gnuplot has standalone="no" at the top so you do have a version that can have the interactive features I suggested.
In particular toggling lines on/off can be a useful feature with this kind of multiple line plot.
Your svg doesn't zoom either :?
Quoted 21 lines · xenophile
Quoted 10 lines · Gilles Chanteperdrix
Quoted 1 line · xenophile
bitmap rendered graphs should be a relic of the 1990's ;)
... but still look much better without getting to much in gnuplot configuration:
http://sisyphus.hd.free.fr/~gilles/core-3.4-latencies/atom.png
http://sisyphus.hd.free.fr/~gilles/core-3.4-latencies/atom.svgThere is a problem with the legend not showing for some reason. If you'd like to send me your gnuplot script and a sample data file I could look what is going wrong. (Off list if you prefer).
You may want to explicitly specify the font size as well since it seems you prefer the smaller text in the png.
Apart from fixing the problem with the legend , where's the "much better"?
Quoted 8 lines
Your gnuplot has standalone="no" at the top so you do have a version that can have the interactive features I suggested.
In particular toggling lines on/off can be a useful feature with this kind of multiple line plot.
Your svg doesn't zoom either :?
Well, the lines are to thick, the fonts are to large, so large that the legend can not be printed (but it is a placement issue due to my script, I know how to fix that), so, overall the graph looks really ugly. The svg graph zooms with my client.
The script is based on scripts/histo.gp in xenomai distribution, with simply "set terminal png..." replaced with "set terminal svg dynamic". I would gladly accept a patch to this file which makes it render good looking svg graphs.
Signature · 1 line
Gilles.
Quoted 29 lines · Gilles Chanteperdrix
Quoted 27 lines · xenophile
Quoted 10 lines · Gilles Chanteperdrix
Quoted 1 line · xenophile
bitmap rendered graphs should be a relic of the 1990's ;)
... but still look much better without getting to much in gnuplot configuration:
http://sisyphus.hd.free.fr/~gilles/core-3.4-latencies/atom.png
http://sisyphus.hd.free.fr/~gilles/core-3.4-latencies/atom.svgThere is a problem with the legend not showing for some reason. If you'd like to send me your gnuplot script and a sample data file I could look what is going wrong. (Off list if you prefer).
You may want to explicitly specify the font size as well since it seems you prefer the smaller text in the png.
Apart from fixing the problem with the legend , where's the "much better"?
Your gnuplot has standalone="no" at the top so you do have a version that can have the interactive features I suggested.
In particular toggling lines on/off can be a useful feature with this kind of multiple line plot.
Quoted 6 lines
Quoted 2 lines
Your svg doesn't zoom either :?
Well, the lines are to thick, the fonts are to large, so large that the legend can not be printed (but it is a placement issue due to my script,
so specify the line width and text size you'd like. There is not an exact 1:1 mapping of line widths between how png and svg render finally.
Also fonts are created on the host machine in the case of png whereas the choice of font is done in the viewer with formats like svg, postscript , pdf which provide text descriptions not dots. It will probably help to explicitly define the font
Quoted 2 lines
I know how to fix that), so, overall the graph looks really ugly. The svg graph zooms with my client.
which is ?
Tested you links on linux firefox-14 and Opera . Mine zoom ,yours don't :?
gnuplot> help svg:
...
dynamic allows a svg-viewer to resize plot, whereas the default setting, fixed, will request an absolute size.
You are inviting the viewer to autoscale, which effectively defeating the one of the (potential) benefits of using a scalable format. Opera shows in it's scaling widget that it is zooming but then autoscales the svg so that I get the same thing on screen.
Since most browsers now seem to autoscale when first showing a graphic even if you don't request it , leaving this out is probably the best option. This may have a bearing on your font size issues too.
Quoted 6 lines
The script is based on
scripts/histo.gpin xenomai distribution, with simply "set terminal png..." replaced with "set terminal svg dynamic". I would gladly accept a patch to this file which makes it render good looking svg graphs.
I don't have xeno installed an any hardware here but I am willing to help you get clean output if you want to link me the script and a sample data file.
I am active on gnuplot ML and was behind getting a lot of this stuff into gnuplot.
eg.
set terminal svg mouse standalone font arial 7
Quoted 42 lines · xenophile
Quoted 29 lines · Gilles Chanteperdrix
Quoted 27 lines · xenophile
Quoted 10 lines · Gilles Chanteperdrix
Quoted 1 line · xenophile
bitmap rendered graphs should be a relic of the 1990's ;)
... but still look much better without getting to much in gnuplot configuration:
http://sisyphus.hd.free.fr/~gilles/core-3.4-latencies/atom.png
http://sisyphus.hd.free.fr/~gilles/core-3.4-latencies/atom.svgThere is a problem with the legend not showing for some reason. If you'd like to send me your gnuplot script and a sample data file I could look what is going wrong. (Off list if you prefer).
You may want to explicitly specify the font size as well since it seems you prefer the smaller text in the png.
Apart from fixing the problem with the legend , where's the "much better"?
Your gnuplot has standalone="no" at the top so you do have a version that can have the interactive features I suggested.
In particular toggling lines on/off can be a useful feature with this kind of multiple line plot.
Quoted 6 lines
Quoted 2 lines
Your svg doesn't zoom either :?
Well, the lines are to thick, the fonts are to large, so large that the legend can not be printed (but it is a placement issue due to my script,
so specify the line width and text size you'd like. There is not an exact 1:1 mapping of line widths between how png and svg render finally.
Quoted 5 lines
Also fonts are created on the host machine in the case of png whereas the choice of font is done in the viewer with formats like svg, postscript , pdf which provide text descriptions not dots. It will
probably help to explicitly define the font
I understand that. And I see a problem here, depending on how the graph is scaled, the legend may fit or not, even depending on what font the client chose as substitute of a font not present on the client side.
As for the line width, I would like it to be 1 pixel whatever the zoom factor or screen size. This does not look very "vector like", but after all lines are the representation of something which has a null width, so should be represented with the smallest possible width: 1 pixel. I see here some "smoothing" of the line despite the fact that I have set the linewidth to "1", so I guess the client is in fact adding the smoothing.
Quoted 7 lines
Quoted 3 lines
I know how to fix that), so, overall the graph looks really ugly. The svg graph zooms with my client.
which is ?
Tested you links on linux firefox-14 and Opera . Mine zoom ,yours don't :?
I meant that it was automatically resized when I maximize the browser window. That is what I meant by "it zooms". Without "terminal svg dynamic", it does not rescale automatically.
Quoted 10 lines
gnuplot> help svg:
...
dynamicallows a svg-viewer to resize plot, whereas the default setting,fixed, will request an absolute size.You are inviting the viewer to autoscale, which effectively defeating the one of the (potential) benefits of using a scalable format. Opera shows in it's scaling widget that it is zooming but then autoscales the svg so that I get the same thing on screen.
Quoted 4 lines
Since most browsers now seem to autoscale when first showing a graphic even if you don't request it , leaving this out is probably the best
option. This may have a bearing on your font size issues too.
Does not work here, my firefox is probably too old (something like version 10).
Quoted 12 lines
Quoted 7 lines
The script is based on
scripts/histo.gpin xenomai distribution, with simply "set terminal png..." replaced with "set terminal svg dynamic". I would gladly accept a patch to this file which makes it render good looking svg graphs.I don't have xeno installed an any hardware here but I am willing to help you get clean output if you want to link me the script and a sample data file.
Quoted 5 lines
I am active on gnuplot ML and was behind getting a lot of this stuff into gnuplot.
eg.
set terminal svg mouse standalone font arial 7
arial is just the font that may not be present on everybody's installation. My gnuplot is simply too old (4.4) for this line to work, neither mouse, nor standalone work here, and the font syntax is different.
All things considered, I am not so sure svg is such a big win.
The script and data I use to build the graph are all in
http://sisyphus.hd.free.fr/~gilles/core-3.4-latencies
starting from
http://sisyphus.hd.free.fr/~gilles/core-3.4-latencies/histo.gp
Signature · 1 line
Gilles.
Quoted 4 lines · Gilles Chanteperdrix
The script and data I use to build the graph are all in
http://sisyphus.hd.free.fr/~gilles/core-3.4-latencies
starting from
http://sisyphus.hd.free.fr/~gilles/core-3.4-latencies/histo.gp
I just tested that with gnuplot 4.6 CVS from April 17th. Output looks nice and clean, no font issues, nice fine lines. Ariel is a pretty safe bet on all platforms, it's also the default.
current 4.6 release was on March 8th 2012 so it will virtually identical. Strongly suggest an update, lots of change and bug fixes since 4.4
Mouse interaction may not have been included that far back. Equally inclusion of the js inside the svg using the standalone option was fairly recent, though IIRC it did get included in the March release. (I was mistaken seeing "standalone" in the markup, that predates this option's effect on js)
The font syntax you use if still supported. gnuplot is pretty hardcore about backwards compatibility.
You should add a final line to close the output file. Gnuplot does not close the file since there could be follow on output to the same file.
unset output
I removed "dynamic" and it scales as expected.
In resumé, removing dynamic should fix a few defects ; update to 4.6 recommended unless that are blocking issues with doing so.
Add the missing line to script.
set terminal svg mouse standalone fname "Arial" fsize 8 linewidth 0.6 butt
....
unset output
Hardly merits a patch.
HTH
Quoted 5 lines · Paul
Thanks for the timely update Gilles - Just finished work on an (unsupported) ARM1176 SoC running at 700MHz and the documents came in handy. Only a rough draft at the moment and some of the kernel options need tuning, but as a starting point, it looks quite reasonable.
Btw, any chance for a publication of this patch?
Signature · 1 line
Gilles.