Stella Laurenzo
4a5695ae9c
Fix createTensorLikeArrayType() declaration.
2020-07-04 20:37:46 -07:00
Stella Laurenzo
00c791f925
Make common utilities for converting TypeNode <-> IR types.
...
* Generalizes the conversions from ObjectValueType <-> tensor and ndarray.
* Creates a utility to construct the default type map hook.
2020-07-04 20:33:13 -07:00
Stella Laurenzo
97c92aa264
Remove the existing attached values/ops from CPA types.
...
This was ad-hoc and needs to be replaced by a more principled track back to the IR.
2020-07-04 17:47:19 -07:00
Stella Laurenzo
48a0b0ec7f
NFC: Move CPATypeInference to Typing directory.
2020-07-04 16:56:09 -07:00
Stella Laurenzo
051d088161
NFC: Move CPA typing analysis down a directory.
2020-07-04 16:40:02 -07:00
Stella Laurenzo
6a50efd046
Extend the CPA type inference to work on numpy types/ops.
...
* Adds an op interface for adding CPA constraints.
* Adds a type conversion hook for handling built-in types (that we can't have adopt our interface).
* Converts tensor<> to object(!Tensor, [e:<type>]) just like NdArray.
* Implement a few numpy ops far enough to do dtype inference for simple sequences.
2020-07-03 18:16:34 -07:00
Stella Laurenzo
34861b18f4
Add NdArray type inference conversion.
2020-07-03 16:38:10 -07:00
Stella Laurenzo
4a2f7c0b5f
Add constraint propagation and tracking of node members.
2020-07-03 13:29:52 -07:00
Stella Laurenzo
1a13c38033
More progress on CPA.
...
* Added transitivity propagation rules.
* Fixed up some copy-n-paste inversions from the old algorithm.
2020-07-02 18:56:05 -07:00
Stella Laurenzo
74b8bed7e3
Unique CPA type and constraints to enable comparison by pointer during propagation.
2020-07-02 17:07:02 -07:00
Stella Laurenzo
a257da46e2
Introduce a type interface for mapping to CPA types.
...
* Currently just simplifies the logic for UnknownType -> TypeVar.
2020-07-02 13:56:27 -07:00
Stella Laurenzo
b0604684ba
NFC: Move CPA support down into it's own directory.
2020-07-02 11:31:23 -07:00
Stella Laurenzo
92190176fb
Add skeleton of pass to do modified PCA type inference.
2020-06-30 20:57:09 -07:00
Stella Laurenzo
f1b08a0ef0
Add some support classes for implementing a CPA type inference algorithm.
2020-06-30 18:28:39 -07:00