• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Zilliqa / scilla / 1268
61%

Build:
DEFAULT BRANCH: master
Ran 24 Apr 2019 04:49PM UTC
Jobs 1
Files 39
Run time 27min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

pending completion
1268

push

travis-ci-com

web-flow
Gas usage analysis for Scilla (#519)

Introducing a static resource analyzer for Scilla.

The analysis computes gas usage of a transition as a polynomial of the size of its parameters and contract fields. The gas usage of a higher-order functions may depend on the gas
usage of its functional argument, as well as on the size of the result value it returns. We capture
this by means of `sizeref` and `guref` (for gas usage reference) that together form a signature. The signature, allowing for higher-orderness can take arguments for substitution later.

This is still a work in progress and some of the TODOs are listed in #519. (There will be separate Issues created and kept track of after this merge).

Commit history:

* multivariate polynomial utility

* add expression analyser. not all expressions supported

* When substituting formals with actuals, resolve actuals from environment.

* Add signature printing functions

* Fix bug in creating lambda. Resolve arguments first.

* resolve inputs to builtins and fix result sizeref.

* support parameter expansion for polynomials

* Resolve and expand sizeref and guref lambdas

* substitution of actuals should replace lambda function names also.

Only a special case where the function being called is direct
(as against wrapped in ADTs) is supported.

* Make GApp printing more friendly

* gas-analysis: Support builtins

* add statement, transition and contract analysis

* add a testsuite for gas analysis

* Substitute all arguments at once, not one by one.

This fixes bug in analyzing tests/gas_use_analysis/expr/app2.scilla.
Previously, substitutions such as [a;b] -> [b;a] in [a;b] would result
in [a;a] instead of [b;a].

* support arbitrary functions of sizerefs

* simplify size references

* Replace BranchTaken sizeref with MaxB. Use for result of MatchExpr.

2. The option to not flatten (add up) gas-use across branches is removed.
3. Simplify Pair sizerefs in... (continued)

3902 of 4820 relevant lines covered (80.95%)

10530.25 hits per line

Jobs
ID Job ID Ran Files Coverage
1 1268.1 24 Apr 2019 04:49PM UTC 0
80.95
Travis Job 1268.1
Source Files on build 1268
Detailed source file information is not available for this build.
  • Back to Repo
  • Build #1268
  • 3a688e06 on github
  • Prev Build on master (#1264)
  • Next Build on master (#1270)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc