Skip to content

Commit

Permalink
Hotfix for version reporting.
Browse files Browse the repository at this point in the history
  • Loading branch information
Mx7f committed Oct 22, 2017
1 parent 512fa1a commit eed03b9
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 7 deletions.
6 changes: 0 additions & 6 deletions API/src/createwrapper.t
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
local libraryname, sourcedirectory, main, headerfile, outputname, embedsource = ...
embedsource = "true" == embedsource or false

require("version")

local ffi = require("ffi")

terralib.includepath = terralib.terrahome.."/include;."
Expand Down Expand Up @@ -140,10 +138,6 @@ local terra NewState(params : Opt_InitializationParameters) : &LibraryState
C.lua_pushnumber(L,verbosityLevel);
C.lua_setfield(L,LUA_GLOBALSINDEX,"_opt_verbosity")

if params.verbosityLevel > 0 then
C.printf("Opt Version: %s\n", [opt_version_string])
end

C.lua_pushboolean(L,params.collectPerKernelTimingInfo);
C.lua_setfield(L,LUA_GLOBALSINDEX,"_opt_collect_kernel_timing")

Expand Down
5 changes: 5 additions & 0 deletions API/src/o.t
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ local ffi = require("ffi")
local util = require("util")
local optlib = require("lib")
ad = require("ad")
require("version")
require("precision")
local A = ad.classes

Expand Down Expand Up @@ -33,6 +34,10 @@ local verboseAD = _opt_verbosity > 1
local vprintfname = ffi.os == "Windows" and "vprintf" or "cudart:vprintf"
local vprintf = terralib.externfunction(vprintfname, {&int8,&int8} -> int)

if verboseSolver then
print("Using Opt "..opt_version_string)
end

local function createbuffer(args)
local Buf = terralib.types.newstruct()
for i,e in ipairs(args) do
Expand Down
2 changes: 1 addition & 1 deletion API/src/version.t
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
opt_version_major = 0
opt_version_minor = 1
opt_version_patch = 0
opt_version_string = tostring(opt_version_major).."."..tostring(opt_version_patch).."."..tostring(opt_version)
opt_version_string = "v"..tostring(opt_version_major).."."..tostring(opt_version_minor).."."..tostring(opt_version_patch)

0 comments on commit eed03b9

Please sign in to comment.