Skip to content

Commit

Permalink
WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
phadej committed Apr 25, 2024
1 parent 1b8ca35 commit e7a4f3c
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 9 deletions.
26 changes: 25 additions & 1 deletion bench/macro/lsm-tree-bench-wp8.hs
Original file line number Diff line number Diff line change
@@ -1,12 +1,36 @@
{-# LANGUAGE NoFieldSelectors #-}
{-# LANGUAGE OverloadedRecordDot #-}
module Main (main) where

import Data.Void (Void)
import qualified Crypto.Hash.SHA256 as SHA256
import qualified Data.ByteString as BS
import qualified Data.ByteString.Short as SBS
import Data.Void (Void)
import qualified Options.Applicative as O

-- We should be able to write this benchmark
-- using only use public lsm-tree interface
import qualified Database.LSMTree.Normal as LSM

type K = BS.ByteString
type V = BS.ByteString
type B = Void

main :: IO ()
main = putStrLn "hello"

data GlobalOpts = GlobalOpts
{ rootDir :: FilePath -- ^ session directory.
}
deriving Show

data Cmd
-- | Setup benchmark: generate initial LSM tree etc.
= CmdSetup

-- | Make a dry run, measure the overhead.
| CmdDryRun

-- | Run the actual benchmark
| CmdRun
deriving Show
12 changes: 4 additions & 8 deletions lsm-tree.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -344,25 +344,21 @@ benchmark lsm-tree-bench-wp8
type: exitcode-stdio-1.0
hs-source-dirs: bench/macro src-extras
main-is: lsm-tree-bench-wp8.hs
other-modules:
Database.LSMTree.Extras.Orphans

other-modules: Database.LSMTree.Extras.Orphans
build-depends:
, base
, lsm-tree
, lsm-tree:bloomfilter
, bytestring
, clock
, cryptohash-sha256
, lsm-tree
, optparse-applicative
, primitive
, random
, time
, vector
, optparse-applicative
, wide-word

ghc-options: -rtsopts -with-rtsopts=-T -threaded


library kmerge
import: language, warnings, wno-x-partial
hs-source-dirs: src-kmerge
Expand Down

0 comments on commit e7a4f3c

Please sign in to comment.