Skip to content

Commit 2d4c560

Browse files
committed
A bit of progress; need to add code to handle exported reductions and to start tieing things together; then need to implement broadcasting, and eventually make sure it will support autodiff.
1 parent cdf4661 commit 2d4c560

File tree

7 files changed

+323
-388
lines changed

7 files changed

+323
-388
lines changed

Manifest.toml

Lines changed: 12 additions & 61 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,6 @@
33
[[Base64]]
44
uuid = "2a0f44e3-6c83-55bd-87e4-b1978d98bd5f"
55

6-
[[Compat]]
7-
deps = ["Base64", "Dates", "DelimitedFiles", "Distributed", "InteractiveUtils", "LibGit2", "Libdl", "LinearAlgebra", "Markdown", "Mmap", "Pkg", "Printf", "REPL", "Random", "Serialization", "SharedArrays", "Sockets", "SparseArrays", "Statistics", "Test", "UUIDs", "Unicode"]
8-
git-tree-sha1 = "ed2c4abadf84c53d9e58510b5fc48912c2336fbb"
9-
uuid = "34da2185-b29b-5c13-b0c7-acf172513d20"
10-
version = "2.2.0"
11-
126
[[CpuId]]
137
deps = ["Markdown", "Test"]
148
git-tree-sha1 = "f0464e499ab9973b43c20f8216d088b61fda80c6"
@@ -21,14 +15,6 @@ git-tree-sha1 = "a1b652fb77ae8ca7ea328fa7ba5aa151036e5c10"
2115
uuid = "864edb3b-99cc-5e75-8d2d-829cb0a9cfe8"
2216
version = "0.17.6"
2317

24-
[[Dates]]
25-
deps = ["Printf"]
26-
uuid = "ade2ca70-3891-5945-98fb-dc099432e06a"
27-
28-
[[DelimitedFiles]]
29-
deps = ["Mmap"]
30-
uuid = "8bb1440f-4735-579b-a4ab-409b98df4dab"
31-
3218
[[Distributed]]
3319
deps = ["Random", "Serialization", "Sockets"]
3420
uuid = "8ba89e20-285c-5b6f-9357-94700520ee1b"
@@ -37,10 +23,6 @@ uuid = "8ba89e20-285c-5b6f-9357-94700520ee1b"
3723
deps = ["Markdown"]
3824
uuid = "b77e0a4c-d291-57a0-90e8-8db25a27a240"
3925

40-
[[LibGit2]]
41-
deps = ["Printf"]
42-
uuid = "76f85450-5226-5b5a-8eaa-529ad045b433"
43-
4426
[[Libdl]]
4527
uuid = "8f399da3-3557-5675-b5ff-fb832c97cbdb"
4628

@@ -52,18 +34,15 @@ uuid = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
5234
uuid = "56ddb016-857b-54e1-b83d-db4d58db5568"
5335

5436
[[MacroTools]]
55-
deps = ["Compat", "DataStructures", "Test"]
56-
git-tree-sha1 = "82921f0e3bde6aebb8e524efc20f4042373c0c06"
37+
deps = ["DataStructures", "Markdown", "Random"]
38+
git-tree-sha1 = "e2fc7a55bb2224e203bbd8b59f72b91323233458"
5739
uuid = "1914dd2f-81c6-5fcd-8719-6d5c9610ff09"
58-
version = "0.5.2"
40+
version = "0.5.3"
5941

6042
[[Markdown]]
6143
deps = ["Base64"]
6244
uuid = "d6f4376e-aef5-505a-96c1-9c027394607a"
6345

64-
[[Mmap]]
65-
uuid = "a63ad114-7e13-5084-954f-fe012c677804"
66-
6746
[[OrderedCollections]]
6847
deps = ["Random", "Serialization", "Test"]
6948
git-tree-sha1 = "c4c13474d23c60d20a67b217f1d7f22a40edf8f1"
@@ -76,68 +55,40 @@ git-tree-sha1 = "b62b2558efb1eef1fa44e4be5ff58a515c287e38"
7655
uuid = "d96e819e-fc66-5662-9728-84c9c7592b0a"
7756
version = "0.12.0"
7857

79-
[[Pkg]]
80-
deps = ["Dates", "LibGit2", "Libdl", "Logging", "Markdown", "Printf", "REPL", "Random", "SHA", "UUIDs"]
81-
uuid = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f"
82-
83-
[[Printf]]
84-
deps = ["Unicode"]
85-
uuid = "de0858da-6303-5e67-8744-51eddeeeb8d7"
86-
87-
[[REPL]]
88-
deps = ["InteractiveUtils", "Markdown", "Sockets"]
89-
uuid = "3fa0cd96-eef1-5676-8a61-b3b8758bbffb"
90-
9158
[[Random]]
9259
deps = ["Serialization"]
9360
uuid = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"
9461

95-
[[SHA]]
96-
uuid = "ea8e919c-243c-51af-8825-aaa63cd721ce"
97-
9862
[[SIMDPirates]]
9963
deps = ["MacroTools", "VectorizationBase"]
100-
path = "/home/chriselrod/.julia/dev/SIMDPirates"
64+
git-tree-sha1 = "18c27a6a5ad4c0fab6a478aca1947061f087d5fd"
65+
repo-rev = "master"
66+
repo-url = "https://github.com/chriselrod/SIMDPirates.jl"
10167
uuid = "21efa798-c60a-11e8-04d3-e1a92915a26a"
10268
version = "0.1.0"
10369

10470
[[SLEEFPirates]]
10571
deps = ["SIMDPirates", "VectorizationBase"]
106-
path = "/home/chriselrod/.julia/dev/SLEEFPirates"
72+
git-tree-sha1 = "05ab2c6c112a2ac249951f847e5ccf448323e98a"
73+
repo-rev = "master"
74+
repo-url = "https://github.com/chriselrod/SLEEFPirates.jl"
10775
uuid = "476501e8-09a2-5ece-8869-fb82de89a1fa"
10876
version = "0.1.0"
10977

11078
[[Serialization]]
11179
uuid = "9e88b42a-f829-5b0c-bbe9-9e923198166b"
11280

113-
[[SharedArrays]]
114-
deps = ["Distributed", "Mmap", "Random", "Serialization"]
115-
uuid = "1a1011a3-84de-559e-8e89-a11a2f7dc383"
116-
11781
[[Sockets]]
11882
uuid = "6462fe0b-24de-5631-8697-dd941f90decc"
11983

120-
[[SparseArrays]]
121-
deps = ["LinearAlgebra", "Random"]
122-
uuid = "2f01184e-e22b-5df5-ae63-d93ebab69eaf"
123-
124-
[[Statistics]]
125-
deps = ["LinearAlgebra", "SparseArrays"]
126-
uuid = "10745b16-79ce-11e8-11f9-7d13ad32a3b2"
127-
12884
[[Test]]
12985
deps = ["Distributed", "InteractiveUtils", "Logging", "Random"]
13086
uuid = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
13187

132-
[[UUIDs]]
133-
deps = ["Random", "SHA"]
134-
uuid = "cf7118a7-6976-5b1a-9a39-7adc72f591a4"
135-
136-
[[Unicode]]
137-
uuid = "4ec0a83e-493e-50e2-b9ac-8f72acf5a8f5"
138-
13988
[[VectorizationBase]]
14089
deps = ["CpuId", "LinearAlgebra"]
141-
path = "/home/chriselrod/.julia/dev/VectorizationBase"
90+
git-tree-sha1 = "5105ee9720b9f4d90059ef1f99506c99c17b95cd"
91+
repo-rev = "master"
92+
repo-url = "https://github.com/chriselrod/VectorizationBase.jl"
14293
uuid = "3d5dd08c-fd9d-11e8-17fa-ed2836048c2f"
14394
version = "0.1.0"

src/contract_pass.jl

Lines changed: 0 additions & 117 deletions
This file was deleted.

src/determinestrategy.jl

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -57,9 +57,10 @@ function evaluate_cost_unroll(
5757
end
5858
iter *= liter
5959
# check which vars we can define at this level of loop nest
60-
for op operations(ls)
60+
for (id,op) enumerate(operations(ls))
6161
# won't define if already defined...
62-
id = identifier(op)
62+
# id = identifier(op)
63+
isconstant(op) && continue
6364
included_vars[id] && continue
6465
# it must also be a subset of defined symbols
6566
loopdependencies(op) nested_loop_syms || continue
@@ -218,7 +219,8 @@ function evaluate_cost_tile(
218219
end
219220
# check which vars we can define at this level of loop nest
220221
for (id, op) enumerate(operations(ls))
221-
@assert id == identifier(op) # testing, for now
222+
isconstant(op) && continue
223+
# @assert id == identifier(op)+1 # testing, for now
222224
# won't define if already defined...
223225
included_vars[id] && continue
224226
# it must also be a subset of defined symbols

0 commit comments

Comments
 (0)