Skip to content

Instantly share code, notes, and snippets.

@fujiwara
Created August 5, 2010 06:42
Show Gist options
  • Select an option

  • Save fujiwara/509354 to your computer and use it in GitHub Desktop.

Select an option

Save fujiwara/509354 to your computer and use it in GitHub Desktop.
$ perl benchmark/others.pl --pp [~/devel/p5-Text-Xslate]
testing with PP
Perl/5.12.1 darwin-2level
Text::Xslate/0.1054
Text::MicroTemplate/0.15
Template/2.22
Text::ClearSilver/0.10.5.4
HTML::Template::Pro/0.9502
1..5
ok 1 - TT: Template-Toolkit
ok 2 - MT: Text::MicroTemplate
ok 3 - TCS: Text::ClearSilver
ok 4 - HTP: HTML::Template::Pro
ok 5 - HT: HTML::Template
Benchmarks with 'list' (datasize=100)
Rate TT Xslate HT MT
TT 96.3/s -- -37% -61% -90%
Xslate 152/s 58% -- -39% -85%
HT 249/s 159% 63% -- -75%
MT 1003/s 941% 558% 303% --
$ git diff
diff --git a/benchmark/template/list.tt b/benchmark/template/list.tt
index 77edd47..8d9517d 100644
--- a/benchmark/template/list.tt
+++ b/benchmark/template/list.tt
@@ -1,6 +1,6 @@
List:
[% FOREACH item IN data -%]
- * [% item.title %]
- * [% item.title %]
- * [% item.title %]
+ * [% item.title | html %]
+ * [% item.title | html %]
+ * [% item.title | html %]
[% END -%]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment