Skip to content

Conversation

@DanielRosenwasser
Copy link
Member

@DanielRosenwasser DanielRosenwasser commented Oct 19, 2019

See motivation at #34552 (comment)

@DanielRosenwasser DanielRosenwasser added the Experiment A fork with an experimental idea which might not make it into master label Oct 19, 2019
@DanielRosenwasser
Copy link
Member Author

@typescript-bot test this
@typescript-bot user test this
@typescript-bot perf test this
@typescript-bot run dt

@typescript-bot
Copy link
Collaborator

typescript-bot commented Oct 19, 2019

Heya @DanielRosenwasser, I've started to run the perf test suite on this PR at 798fa05. You can monitor the build here. It should now contribute to this PR's status checks.

Update: The results are in!

@typescript-bot
Copy link
Collaborator

typescript-bot commented Oct 19, 2019

Heya @DanielRosenwasser, I've started to run the extended test suite on this PR at 798fa05. You can monitor the build here. It should now contribute to this PR's status checks.

@typescript-bot
Copy link
Collaborator

typescript-bot commented Oct 19, 2019

Heya @DanielRosenwasser, I've started to run the parallelized Definitely Typed test suite on this PR at 798fa05. You can monitor the build here. It should now contribute to this PR's status checks.

@typescript-bot
Copy link
Collaborator

typescript-bot commented Oct 19, 2019

Heya @DanielRosenwasser, I've started to run the parallelized community code test suite on this PR at 798fa05. You can monitor the build here. It should now contribute to this PR's status checks.

@typescript-bot
Copy link
Collaborator

The user suite test run you requested has finished and failed. I've opened a PR with the baseline diff from master.

@typescript-bot
Copy link
Collaborator

@DanielRosenwasser
The results of the perf run you requested are in!

Here they are:

Comparison Report - master..34598

Metric master 34598 Delta Best Worst
Angular - node (v10.16.3, x64)
Memory used 355,210k (± 0.02%) 356,449k (± 0.02%) +1,239k (+ 0.35%) 356,267k 356,642k
Parse Time 1.61s (± 0.56%) 1.62s (± 0.77%) +0.01s (+ 0.37%) 1.59s 1.64s
Bind Time 0.86s (± 0.87%) 0.86s (± 0.95%) -0.00s (- 0.00%) 0.84s 0.88s
Check Time 4.51s (± 0.71%) 4.50s (± 0.33%) -0.01s (- 0.20%) 4.46s 4.54s
Emit Time 5.26s (± 0.59%) 5.26s (± 0.61%) -0.00s (- 0.00%) 5.20s 5.35s
Total Time 12.25s (± 0.33%) 12.24s (± 0.41%) -0.01s (- 0.06%) 12.12s 12.34s
Monaco - node (v10.16.3, x64)
Memory used 365,956k (± 0.01%) 366,961k (± 0.02%) +1,005k (+ 0.27%) 366,802k 367,264k
Parse Time 1.26s (± 0.60%) 1.25s (± 0.76%) -0.00s (- 0.08%) 1.24s 1.27s
Bind Time 0.75s (± 0.86%) 0.75s (± 0.69%) -0.00s (- 0.13%) 0.74s 0.76s
Check Time 4.65s (± 0.61%) 4.61s (± 0.55%) -0.05s (- 0.97%) 4.52s 4.64s
Emit Time 2.97s (± 0.90%) 2.97s (± 0.49%) -0.00s (- 0.10%) 2.94s 3.00s
Total Time 9.63s (± 0.56%) 9.58s (± 0.32%) -0.05s (- 0.54%) 9.48s 9.62s
TFS - node (v10.16.3, x64)
Memory used 321,609k (± 0.02%) 322,562k (± 0.03%) +953k (+ 0.30%) 322,375k 322,732k
Parse Time 0.95s (± 0.70%) 0.95s (± 0.61%) -0.00s (- 0.31%) 0.94s 0.96s
Bind Time 0.72s (± 1.11%) 0.72s (± 1.47%) +0.00s (+ 0.42%) 0.70s 0.74s
Check Time 4.09s (± 0.48%) 4.11s (± 0.47%) +0.02s (+ 0.37%) 4.05s 4.15s
Emit Time 3.05s (± 1.11%) 3.03s (± 0.80%) -0.02s (- 0.75%) 2.97s 3.07s
Total Time 8.82s (± 0.47%) 8.81s (± 0.33%) -0.01s (- 0.09%) 8.74s 8.87s
Angular - node (v12.1.0, x64)
Memory used 330,529k (± 0.08%) 331,946k (± 0.07%) +1,417k (+ 0.43%) 331,097k 332,220k
Parse Time 1.56s (± 0.72%) 1.57s (± 0.86%) +0.01s (+ 0.51%) 1.55s 1.61s
Bind Time 0.84s (± 1.39%) 0.84s (± 1.06%) +0.00s (+ 0.36%) 0.83s 0.87s
Check Time 4.44s (± 0.83%) 4.43s (± 0.61%) -0.01s (- 0.23%) 4.38s 4.50s
Emit Time 5.46s (± 0.96%) 5.46s (± 0.90%) +0.01s (+ 0.13%) 5.38s 5.56s
Total Time 12.30s (± 0.77%) 12.31s (± 0.60%) +0.01s (+ 0.09%) 12.14s 12.44s
Monaco - node (v12.1.0, x64)
Memory used 345,750k (± 0.01%) 346,742k (± 0.02%) +992k (+ 0.29%) 346,661k 346,877k
Parse Time 1.22s (± 0.61%) 1.22s (± 0.64%) +0.00s (+ 0.16%) 1.21s 1.24s
Bind Time 0.72s (± 1.01%) 0.72s (± 0.62%) 0.00s ( 0.00%) 0.71s 0.73s
Check Time 4.45s (± 0.50%) 4.47s (± 0.45%) +0.02s (+ 0.45%) 4.43s 4.51s
Emit Time 2.99s (± 0.49%) 3.00s (± 0.90%) +0.01s (+ 0.50%) 2.95s 3.08s
Total Time 9.38s (± 0.35%) 9.42s (± 0.42%) +0.03s (+ 0.36%) 9.34s 9.50s
TFS - node (v12.1.0, x64)
Memory used 303,963k (± 0.03%) 304,928k (± 0.02%) +965k (+ 0.32%) 304,825k 305,078k
Parse Time 0.95s (± 0.78%) 0.94s (± 0.50%) -0.01s (- 0.74%) 0.93s 0.95s
Bind Time 0.68s (± 0.91%) 0.68s (± 1.54%) +0.00s (+ 0.29%) 0.67s 0.72s
Check Time 4.05s (± 0.40%) 4.04s (± 0.44%) -0.02s (- 0.39%) 4.00s 4.08s
Emit Time 3.07s (± 0.70%) 3.08s (± 0.52%) +0.01s (+ 0.20%) 3.04s 3.11s
Total Time 8.76s (± 0.39%) 8.75s (± 0.33%) -0.02s (- 0.18%) 8.70s 8.82s
Angular - node (v8.9.0, x64)
Memory used 349,872k (± 0.02%) 351,207k (± 0.02%) +1,335k (+ 0.38%) 351,064k 351,433k
Parse Time 2.10s (± 0.50%) 2.10s (± 0.52%) +0.01s (+ 0.24%) 2.08s 2.14s
Bind Time 0.89s (± 0.85%) 0.90s (± 0.89%) +0.01s (+ 0.89%) 0.88s 0.92s
Check Time 5.23s (± 0.43%) 5.27s (± 0.55%) +0.04s (+ 0.67%) 5.22s 5.33s
Emit Time 6.23s (± 1.10%) 6.26s (± 1.26%) +0.03s (+ 0.43%) 6.08s 6.48s
Total Time 14.46s (± 0.57%) 14.53s (± 0.69%) +0.08s (+ 0.54%) 14.29s 14.79s
Monaco - node (v8.9.0, x64)
Memory used 363,758k (± 0.01%) 364,705k (± 0.01%) +946k (+ 0.26%) 364,580k 364,800k
Parse Time 1.56s (± 0.26%) 1.56s (± 0.30%) -0.00s (- 0.06%) 1.55s 1.57s
Bind Time 0.91s (± 0.74%) 0.91s (± 0.65%) 0.00s ( 0.00%) 0.90s 0.93s
Check Time 5.50s (± 0.54%) 5.53s (± 0.52%) +0.03s (+ 0.47%) 5.46s 5.61s
Emit Time 3.05s (± 0.56%) 3.05s (± 0.40%) -0.00s (- 0.00%) 3.02s 3.08s
Total Time 11.03s (± 0.21%) 11.05s (± 0.37%) +0.02s (+ 0.19%) 10.95s 11.17s
TFS - node (v8.9.0, x64)
Memory used 320,479k (± 0.02%) 321,389k (± 0.01%) +910k (+ 0.28%) 321,260k 321,484k
Parse Time 1.27s (± 0.61%) 1.27s (± 0.53%) +0.00s (+ 0.32%) 1.27s 1.30s
Bind Time 0.74s (± 0.98%) 0.74s (± 0.81%) -0.01s (- 0.81%) 0.73s 0.75s
Check Time 4.72s (± 0.61%) 4.71s (± 0.62%) -0.00s (- 0.08%) 4.67s 4.78s
Emit Time 3.22s (± 0.61%) 3.21s (± 0.75%) -0.01s (- 0.40%) 3.14s 3.27s
Total Time 9.95s (± 0.47%) 9.93s (± 0.45%) -0.02s (- 0.21%) 9.82s 10.06s
Angular - node (v8.9.0, x86)
Memory used 198,635k (± 0.02%) 199,194k (± 0.03%) +559k (+ 0.28%) 199,045k 199,324k
Parse Time 2.02s (± 0.67%) 2.03s (± 0.95%) +0.01s (+ 0.64%) 2.00s 2.09s
Bind Time 1.02s (± 0.98%) 1.03s (± 0.97%) +0.00s (+ 0.39%) 1.00s 1.05s
Check Time 4.77s (± 0.44%) 4.83s (± 0.46%) +0.05s (+ 1.11%) 4.78s 4.87s
Emit Time 6.11s (± 1.33%) 6.08s (± 1.76%) -0.03s (- 0.49%) 5.78s 6.31s
Total Time 13.93s (± 0.61%) 13.97s (± 0.87%) +0.04s (+ 0.30%) 13.69s 14.19s
Monaco - node (v8.9.0, x86)
Memory used 203,737k (± 0.01%) 204,231k (± 0.02%) +494k (+ 0.24%) 204,139k 204,324k
Parse Time 1.61s (± 0.37%) 1.61s (± 0.51%) +0.00s (+ 0.00%) 1.59s 1.62s
Bind Time 0.75s (± 1.07%) 0.75s (± 1.07%) +0.00s (+ 0.00%) 0.74s 0.77s
Check Time 5.33s (± 1.35%) 5.37s (± 0.99%) +0.04s (+ 0.71%) 5.19s 5.44s
Emit Time 2.90s (± 3.08%) 2.88s (± 2.35%) -0.02s (- 0.55%) 2.83s 3.14s
Total Time 10.58s (± 0.30%) 10.61s (± 0.50%) +0.02s (+ 0.20%) 10.48s 10.73s
TFS - node (v8.9.0, x86)
Memory used 180,466k (± 0.02%) 180,948k (± 0.02%) +482k (+ 0.27%) 180,897k 181,025k
Parse Time 1.31s (± 0.53%) 1.31s (± 0.59%) -0.00s (- 0.15%) 1.29s 1.32s
Bind Time 0.70s (± 0.79%) 0.70s (± 1.15%) -0.00s (- 0.57%) 0.68s 0.72s
Check Time 4.48s (± 0.50%) 4.50s (± 0.79%) +0.02s (+ 0.47%) 4.44s 4.58s
Emit Time 2.97s (± 0.94%) 2.94s (± 1.00%) -0.03s (- 0.91%) 2.88s 3.00s
Total Time 9.46s (± 0.35%) 9.44s (± 0.56%) -0.01s (- 0.15%) 9.36s 9.57s
System
Machine Namets-ci-ubuntu
Platformlinux 4.4.0-161-generic
Architecturex64
Available Memory16 GB
Available Memory6 GB
CPUs4 × Intel(R) Core(TM) i7-4770 CPU @ 3.40GHz
Hosts
  • node (v10.16.3, x64)
  • node (v12.1.0, x64)
  • node (v8.9.0, x64)
  • node (v8.9.0, x86)
Scenarios
  • Angular - node (v10.16.3, x64)
  • Angular - node (v12.1.0, x64)
  • Angular - node (v8.9.0, x64)
  • Angular - node (v8.9.0, x86)
  • Monaco - node (v10.16.3, x64)
  • Monaco - node (v12.1.0, x64)
  • Monaco - node (v8.9.0, x64)
  • Monaco - node (v8.9.0, x86)
  • TFS - node (v10.16.3, x64)
  • TFS - node (v12.1.0, x64)
  • TFS - node (v8.9.0, x64)
  • TFS - node (v8.9.0, x86)
Benchmark Name Iterations
Current 34598 10
Baseline master 10

@DanielRosenwasser DanielRosenwasser force-pushed the weakTypeChecksComparability branch from 798fa05 to b7e9cea Compare October 19, 2019 19:30
@DanielRosenwasser
Copy link
Member Author

@typescript-bot test this
@typescript-bot user test this
@typescript-bot run dt

@typescript-bot
Copy link
Collaborator

typescript-bot commented Oct 19, 2019

Heya @DanielRosenwasser, I've started to run the parallelized Definitely Typed test suite on this PR at b7e9cea. You can monitor the build here. It should now contribute to this PR's status checks.

@typescript-bot
Copy link
Collaborator

typescript-bot commented Oct 19, 2019

Heya @DanielRosenwasser, I've started to run the parallelized community code test suite on this PR at b7e9cea. You can monitor the build here. It should now contribute to this PR's status checks.

@typescript-bot
Copy link
Collaborator

typescript-bot commented Oct 19, 2019

Heya @DanielRosenwasser, I've started to run the extended test suite on this PR at b7e9cea. You can monitor the build here. It should now contribute to this PR's status checks.

@DanielRosenwasser
Copy link
Member Author

DanielRosenwasser commented Oct 19, 2019

Found one break in DefinitelyTyped in chrome-apps which was legitimate.

/home/vsts/work/1/s/dtslint-runner/DefinitelyTyped/types/chrome-apps/test/index.ts:1645:9
Operator '>' cannot be applied to types 'StorageChange' and 'number'.

https://github.com/DefinitelyTyped/DefinitelyTyped/blob/b0503ac10547e9e087febf36e83c600a62c444bb/types/chrome-apps/test/index.ts#L1644-L1648

changes is a Record<string, StorageChange>, which means you can access any property (which is dumb).

https://github.com/DefinitelyTyped/DefinitelyTyped/blob/b0503ac10547e9e087febf36e83c600a62c444bb/types/chrome-apps/index.d.ts#L9037

But that means that length has the type StorageChange. Arguable that never letting users access arbitrary properties in the presence of index signatures would have prevented this better.

@jack-williams
Copy link
Collaborator

Just throwing this out thereas a terrible suggestion.

If a castable relation is being added, might it be reasonable to allow interfaces to be open when casting to. It avoids the pain of the following:

interface Foo {
    x: string;
    y: string;
}

interface JSONObj {
    [prop: string]: JSONableSub;
}

type JSONableSub = number | string | JSONObj;

declare const obj: JSONableSub;
const foo: Foo = obj as Foo; // error, Foo isn't assignable to JSONObj because it is an interface with no index signature.

@DanielRosenwasser
Copy link
Member Author

@typescript-bot pack this

@typescript-bot
Copy link
Collaborator

typescript-bot commented Oct 21, 2019

Heya @DanielRosenwasser, I've started to run the tarball bundle task on this PR at b7e9cea. You can monitor the build here. It should now contribute to this PR's status checks.

@sandersn
Copy link
Member

This experiment is pretty old, so I'm going to close it to reduce the number of open PRs.

@sandersn sandersn closed this May 24, 2022
@microsoft microsoft locked as resolved and limited conversation to collaborators Oct 21, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Experiment A fork with an experimental idea which might not make it into master

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants