[Git][ghc/ghc][master] Unicode: General Category size test (related #24789)

Marge Bot (@marge-bot) gitlab at gitlab.haskell.org
Mon May 20 01:29:36 UTC 2024



Marge Bot pushed to branch master at Glasgow Haskell Compiler / GHC


Commits:
7d3d9bbf by Serge S. Gulin at 2024-05-19T18:47:05+00:00
Unicode: General Category size test (related #24789)

Added trivial size performance test which involves unicode general category usage via `read`.
The `read` itself uses general category to detect spaces.

The purpose for this test is to measure outcome of applying improvements at General Category representation in code discussed at #24789.

- - - - -


2 changed files:

- testsuite/tests/perf/size/all.T
- + testsuite/tests/perf/size/size_hello_unicode.hs


Changes:

=====================================
testsuite/tests/perf/size/all.T
=====================================
@@ -3,6 +3,8 @@ test('size_hello_obj', [collect_size(5, 'size_hello_obj.o')], compile, [''])
 test('size_hello_artifact', [collect_size(5, 'size_hello_artifact' + exe_extension())],
                              compile_artifact, [''])
 
+test('size_hello_unicode', [collect_size(5, 'size_hello_unicode' + exe_extension())], compile_artifact, [''])
+
 size_acceptance_threshold = 100
 
 test('array_dir'           ,[collect_size_ghc_pkg(size_acceptance_threshold , 'array')]           , static_stats , [] )


=====================================
testsuite/tests/perf/size/size_hello_unicode.hs
=====================================
@@ -0,0 +1,5 @@
+-- same as size_hello_artifact but we test the size of the resulting executable with unicode general category involved.
+module Main where
+
+-- read uses unicode general category to detect spaces
+main = print (read @Int "1337")



View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/7d3d9bbf13745751cb20882b86b148b8e98f77a7

-- 
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/7d3d9bbf13745751cb20882b86b148b8e98f77a7
You're receiving this email because of your account on gitlab.haskell.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20240519/230b03a5/attachment.html>


More information about the ghc-commits mailing list