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

Zilliqa / scilla / 1268 / 1
61%
master: 61%

Build:
DEFAULT BRANCH: master
Ran 24 Apr 2019 04:49PM UTC
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

24 Apr 2019 04:45PM UTC coverage: 80.954% (-1.1%) from 82.025%
1268.1

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

Source Files on job 1268.1
  • Tree
  • List 0
  • Changed 31
  • Source Changed 4
  • Coverage Changed 31
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 545
  • Travis Job 1268.1
  • 3a688e06 on github
  • Prev Job for on master (#1264.1)
  • Next Job for on master (#1270.1)
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