Last active
October 3, 2017 22:24
-
-
Save paurkedal/a7e8c35f5791866b4cba4fdb2b8415da to your computer and use it in GitHub Desktop.
faster-map with new base implementation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8" standalone="no"?> | |
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" | |
"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> | |
<svg | |
width="600" height="500" | |
viewBox="0 0 600 500" | |
xmlns="http://www.w3.org/2000/svg" | |
xmlns:xlink="http://www.w3.org/1999/xlink" | |
> | |
<title>Gnuplot</title> | |
<desc>Produced by GNUPLOT 5.0 patchlevel 5 </desc> | |
<g id="gnuplot_canvas"> | |
<rect x="0" y="0" width="600" height="500" fill="none"/> | |
<defs> | |
<circle id='gpDot' r='0.5' stroke-width='0.5'/> | |
<path id='gpPt0' stroke-width='0.190' stroke='currentColor' d='M-1,0 h2 M0,-1 v2'/> | |
<path id='gpPt1' stroke-width='0.190' stroke='currentColor' d='M-1,-1 L1,1 M1,-1 L-1,1'/> | |
<path id='gpPt2' stroke-width='0.190' stroke='currentColor' d='M-1,0 L1,0 M0,-1 L0,1 M-1,-1 L1,1 M-1,1 L1,-1'/> | |
<rect id='gpPt3' stroke-width='0.190' stroke='currentColor' x='-1' y='-1' width='2' height='2'/> | |
<rect id='gpPt4' stroke-width='0.190' stroke='currentColor' fill='currentColor' x='-1' y='-1' width='2' height='2'/> | |
<circle id='gpPt5' stroke-width='0.190' stroke='currentColor' cx='0' cy='0' r='1'/> | |
<use xlink:href='#gpPt5' id='gpPt6' fill='currentColor' stroke='none'/> | |
<path id='gpPt7' stroke-width='0.190' stroke='currentColor' d='M0,-1.33 L-1.33,0.67 L1.33,0.67 z'/> | |
<use xlink:href='#gpPt7' id='gpPt8' fill='currentColor' stroke='none'/> | |
<use xlink:href='#gpPt7' id='gpPt9' stroke='currentColor' transform='rotate(180)'/> | |
<use xlink:href='#gpPt9' id='gpPt10' fill='currentColor' stroke='none'/> | |
<use xlink:href='#gpPt3' id='gpPt11' stroke='currentColor' transform='rotate(45)'/> | |
<use xlink:href='#gpPt11' id='gpPt12' fill='currentColor' stroke='none'/> | |
<path id='gpPt13' stroke-width='0.190' stroke='currentColor' d='M0,1.330 L1.265,0.411 L0.782,-1.067 L-0.782,-1.076 L-1.265,0.411 z'/> | |
<use xlink:href='#gpPt13' id='gpPt14' fill='currentColor' stroke='none'/> | |
<filter id='textbox' filterUnits='objectBoundingBox' x='0' y='0' height='1' width='1'> | |
<feFlood flood-color='white' flood-opacity='1' result='bgnd'/> | |
<feComposite in='SourceGraphic' in2='bgnd' operator='atop'/> | |
</filter> | |
<filter id='greybox' filterUnits='objectBoundingBox' x='0' y='0' height='1' width='1'> | |
<feFlood flood-color='lightgrey' flood-opacity='1' result='grey'/> | |
<feComposite in='SourceGraphic' in2='grey' operator='atop'/> | |
</filter> | |
</defs> | |
<g fill="none" color="white" stroke="currentColor" stroke-width="1.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='black' d='M84.0,432.8 M570.8,432.8 '/> <g transform="translate(74.3,437.4)" stroke="none" fill="black" font-family="Helvetica" font-size="14.00" text-anchor="end"> | |
<text><tspan font-family="Helvetica" > 0</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='black' d='M84.0,375.9 M570.8,375.9 '/> <g transform="translate(74.3,380.5)" stroke="none" fill="black" font-family="Helvetica" font-size="14.00" text-anchor="end"> | |
<text><tspan font-family="Helvetica" > 20</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='black' d='M84.0,319.0 M570.8,319.0 '/> <g transform="translate(74.3,323.6)" stroke="none" fill="black" font-family="Helvetica" font-size="14.00" text-anchor="end"> | |
<text><tspan font-family="Helvetica" > 40</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='black' d='M84.0,262.2 M570.8,262.2 '/> <g transform="translate(74.3,266.8)" stroke="none" fill="black" font-family="Helvetica" font-size="14.00" text-anchor="end"> | |
<text><tspan font-family="Helvetica" > 60</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='black' d='M84.0,205.3 M570.8,205.3 '/> <g transform="translate(74.3,209.9)" stroke="none" fill="black" font-family="Helvetica" font-size="14.00" text-anchor="end"> | |
<text><tspan font-family="Helvetica" > 80</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='black' d='M84.0,148.4 M570.8,148.4 '/> <g transform="translate(74.3,153.0)" stroke="none" fill="black" font-family="Helvetica" font-size="14.00" text-anchor="end"> | |
<text><tspan font-family="Helvetica" > 100</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='black' d='M84.0,91.5 M570.8,91.5 '/> <g transform="translate(74.3,96.1)" stroke="none" fill="black" font-family="Helvetica" font-size="14.00" text-anchor="end"> | |
<text><tspan font-family="Helvetica" > 120</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='black' d='M84.0,432.8 M84.0,63.1 '/> <g transform="translate(84.0,458.4)" stroke="none" fill="black" font-family="Helvetica" font-size="14.00" text-anchor="middle"> | |
<text><tspan font-family="Helvetica" > 1000</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='black' d='M246.3,432.8 M246.3,63.1 '/> <g transform="translate(246.3,458.4)" stroke="none" fill="black" font-family="Helvetica" font-size="14.00" text-anchor="middle"> | |
<text><tspan font-family="Helvetica" > 10000</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='black' d='M408.5,432.8 M408.5,63.1 '/> <g transform="translate(408.5,458.4)" stroke="none" fill="black" font-family="Helvetica" font-size="14.00" text-anchor="middle"> | |
<text><tspan font-family="Helvetica" > 100000</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='black' d='M570.8,432.8 M570.8,63.1 '/> <g transform="translate(570.8,458.4)" stroke="none" fill="black" font-family="Helvetica" font-size="14.00" text-anchor="middle"> | |
<text><tspan font-family="Helvetica" > 1x10</tspan><tspan font-family="Helvetica" font-size="11.2" dy="-7.00px">6</tspan><tspan font-size="14.0" dy="7.00"></tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
<g transform="translate(19.8,248.0) rotate(270)" stroke="none" fill="black" font-family="Helvetica" font-size="14.00" text-anchor="middle"> | |
<text><tspan font-family="Helvetica" >Time relative to naive tail-recursive version (%)</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
<g transform="translate(327.4,489.9)" stroke="none" fill="black" font-family="Helvetica" font-size="14.00" text-anchor="middle"> | |
<text><tspan font-family="Helvetica" >List size (no. of elements)</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
<g transform="translate(327.4,36.2)" stroke="none" fill="black" font-family="Helvetica" font-size="14.00" text-anchor="middle"> | |
<text><tspan font-family="Helvetica" >Time elapsed (relative) – lower is better</tspan></text> | |
</g> | |
</g> | |
<g id="gnuplot_plot_1" ><title>base</title> | |
<g fill="none" color="white" stroke="black" stroke-width="3.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="3.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
<g transform="translate(202.0,358.4)" stroke="none" fill="black" font-family="Helvetica" font-size="13.00" text-anchor="end"> | |
<text><tspan font-family="Helvetica" >base</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="3.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='gray' stroke-dasharray='3.0,6.0' d='M211.1,354.1 L258.0,354.1 M84.0,148.4 L124.6,148.4 L165.1,148.4 L205.7,148.4 L246.3,148.4 L286.8,148.4 | |
L327.4,148.4 L368.0,148.4 L408.5,148.4 L449.1,148.4 L489.7,148.4 L530.2,148.4 L570.8,148.4 '/></g> | |
</g> | |
<g id="gnuplot_plot_2" ><title>tupled-4</title> | |
<g fill="none" color="white" stroke="gray" stroke-width="1.50" stroke-linecap="butt" stroke-linejoin="miter"> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.50" stroke-linecap="butt" stroke-linejoin="miter"> | |
<g transform="translate(202.0,377.9)" stroke="none" fill="black" font-family="Helvetica" font-size="13.00" text-anchor="end"> | |
<text><tspan font-family="Helvetica" >tupled-4</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.50" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='gray' d='M211.1,373.6 L258.0,373.6 M206.3,63.1 L246.3,121.4 L286.8,168.0 L327.4,193.3 L368.0,212.6 L408.5,221.8 | |
L449.1,209.4 L489.7,200.7 L530.2,211.3 L570.8,223.4 '/></g> | |
</g> | |
<g id="gnuplot_plot_3" ><title>tupled-5</title> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.50" stroke-linecap="butt" stroke-linejoin="miter"> | |
<g transform="translate(202.0,397.4)" stroke="none" fill="black" font-family="Helvetica" font-size="13.00" text-anchor="end"> | |
<text><tspan font-family="Helvetica" >tupled-5</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.50" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='rgb(148, 0, 211)' d='M211.1,393.1 L258.0,393.1 M84.0,95.1 L124.6,79.4 L165.1,80.7 L205.7,86.3 L246.3,148.2 L286.8,186.7 | |
L327.4,217.3 L368.0,241.5 L408.5,227.8 L449.1,224.1 L489.7,213.4 L530.2,225.9 L570.8,240.5 '/></g> | |
</g> | |
<g id="gnuplot_plot_4" ><title>tupled-6</title> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.50" stroke-linecap="butt" stroke-linejoin="miter"> | |
<g transform="translate(202.0,416.9)" stroke="none" fill="black" font-family="Helvetica" font-size="13.00" text-anchor="end"> | |
<text><tspan font-family="Helvetica" >tupled-6</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.50" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='rgb( 0, 158, 115)' d='M211.1,412.6 L258.0,412.6 M84.0,116.9 L124.6,95.8 L165.1,92.7 L205.7,111.8 L246.3,166.5 L286.8,214.6 | |
L327.4,217.0 L368.0,278.0 L408.5,242.1 L449.1,233.4 L489.7,224.2 L530.2,234.0 L570.8,248.7 '/></g> | |
</g> | |
<g id="gnuplot_plot_5" ><title>tupled-7</title> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.50" stroke-linecap="butt" stroke-linejoin="miter"> | |
<g transform="translate(349.0,358.4)" stroke="none" fill="black" font-family="Helvetica" font-size="13.00" text-anchor="end"> | |
<text><tspan font-family="Helvetica" >tupled-7</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.50" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='rgb( 86, 180, 233)' d='M358.1,354.1 L405.0,354.1 M84.0,120.9 L124.6,116.9 L165.1,104.9 L205.7,108.5 L246.3,174.2 L286.8,212.1 | |
L327.4,238.4 L368.0,250.3 L408.5,247.5 L449.1,237.4 L489.7,229.4 L530.2,237.9 L570.8,254.2 '/></g> | |
</g> | |
<g id="gnuplot_plot_6" ><title>tupled-8</title> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.50" stroke-linecap="butt" stroke-linejoin="miter"> | |
<g transform="translate(349.0,377.9)" stroke="none" fill="black" font-family="Helvetica" font-size="13.00" text-anchor="end"> | |
<text><tspan font-family="Helvetica" >tupled-8</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.50" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='rgb(230, 159, 0)' d='M358.1,373.6 L405.0,373.6 M84.0,138.7 L124.6,132.0 L165.1,132.6 L205.7,133.2 L246.3,194.9 L286.8,223.6 | |
L327.4,247.4 L368.0,254.1 L408.5,251.4 L449.1,247.0 L489.7,233.4 L530.2,239.0 L570.8,255.7 '/></g> | |
</g> | |
<g id="gnuplot_plot_7" ><title>tupled-9</title> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.50" stroke-linecap="butt" stroke-linejoin="miter"> | |
<g transform="translate(349.0,397.4)" stroke="none" fill="black" font-family="Helvetica" font-size="13.00" text-anchor="end"> | |
<text><tspan font-family="Helvetica" >tupled-9</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.50" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='rgb(240, 228, 66)' d='M358.1,393.1 L405.0,393.1 M84.0,136.3 L124.6,129.8 L165.1,133.0 L205.7,137.5 L246.3,196.2 L286.8,231.0 | |
L327.4,247.2 L368.0,268.0 L408.5,253.4 L449.1,248.6 L489.7,243.2 L530.2,244.1 L570.8,251.8 '/></g> | |
</g> | |
<g id="gnuplot_plot_8" ><title>tupled-10</title> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.50" stroke-linecap="butt" stroke-linejoin="miter"> | |
<g transform="translate(349.0,416.9)" stroke="none" fill="black" font-family="Helvetica" font-size="13.00" text-anchor="end"> | |
<text><tspan font-family="Helvetica" >tupled-10</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.50" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='rgb( 0, 114, 178)' d='M358.1,412.6 L405.0,412.6 M84.0,107.2 L124.6,105.7 L165.1,112.4 L205.7,124.7 L246.3,187.5 L286.8,228.0 | |
L327.4,250.9 L368.0,256.6 L408.5,254.4 L449.1,250.0 L489.7,244.4 L530.2,247.4 L570.8,252.8 '/></g> | |
</g> | |
<g id="gnuplot_plot_9" ><title>tupled-11</title> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.50" stroke-linecap="butt" stroke-linejoin="miter"> | |
<g transform="translate(496.0,358.4)" stroke="none" fill="black" font-family="Helvetica" font-size="13.00" text-anchor="end"> | |
<text><tspan font-family="Helvetica" >tupled-11</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.50" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='rgb(229, 30, 16)' d='M505.1,354.1 L552.0,354.1 M84.0,92.7 L124.6,94.0 L165.1,106.7 L205.7,120.3 L246.3,186.3 L286.8,229.4 | |
L327.4,254.8 L368.0,268.0 L408.5,258.3 L449.1,252.8 L489.7,246.2 L530.2,249.1 L570.8,252.9 '/></g> | |
</g> | |
<g id="gnuplot_plot_10" ><title>tupled-12</title> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.50" stroke-linecap="butt" stroke-linejoin="miter"> | |
<g transform="translate(496.0,377.9)" stroke="none" fill="black" font-family="Helvetica" font-size="13.00" text-anchor="end"> | |
<text><tspan font-family="Helvetica" >tupled-12</tspan></text> | |
</g> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.50" stroke-linecap="butt" stroke-linejoin="miter"> | |
<path stroke='rgb( 0, 0, 0)' d='M505.1,373.6 L552.0,373.6 M84.0,91.9 L124.6,96.6 L165.1,104.5 L205.7,108.4 L246.3,188.5 L286.8,230.7 | |
L327.4,254.9 L368.0,274.3 L408.5,260.3 L449.1,266.5 L489.7,246.6 L530.2,254.9 L570.8,250.9 '/></g> | |
</g> | |
<g fill="none" color="white" stroke="rgb( 0, 0, 0)" stroke-width="2.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="2.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
</g> | |
<g fill="none" color="black" stroke="black" stroke-width="1.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
</g> | |
<g fill="none" color="black" stroke="currentColor" stroke-width="1.00" stroke-linecap="butt" stroke-linejoin="miter"> | |
</g> | |
</g> | |
</svg> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment