update readme; add smp parameter

This commit is contained in:
xenia 2020-11-16 18:38:49 -05:00
parent bb3a422a57
commit d00abe5db9
2 changed files with 22 additions and 14 deletions

View File

@ -26,9 +26,9 @@ takes the difficulty out of creating custom brute force jobs
### base
- 🚧 input space manipulation functions
- ✅ data types: interval, iset (interval set), pattern (vector of interval set)
- ✅ pos->iset-pos, iset-count, pattern-count
- 🚧 partitioning functions
- ✅ data types: using data/integer-set, pattern (vector of integer-set)
- ✅ basic manipulation functions
- ✅ representation of input space as a flat integer
- 🚧 #lang for configuration/definitions
- (input) mode
- stdio: user program gets input by stdio, integers separated by space, one per line
@ -38,17 +38,17 @@ takes the difficulty out of creating custom brute force jobs
- SMP: performed by crossfire or performed by the user code
- "performed by user code" can also mean GPU, for example
- 🚧 codegen for input generator (in C)
- 🚧 stdio mode
- stdio mode
- 🚧 callback mode
- success reporting mechanism
- low priority: configurable "character" type -- currently a "character" is a uint64\_t
### server: distribute jobs to workers
- base definitions of input classes and how to divide them
- base definitions of input classes and how to divide them
- dynamic slicing and scheduling based on agents' reported work rate
- low priority: randomized input space distribution
- ability to compile input generator with different parameters and distribute to agents
- low priority: support for multiple architectures
- accept submitted projects (with client-compiled input generator) and distribute to agents
- low priority: support for multiple architectures
- ✅ agent authentication
- ✅ client authentication
@ -66,6 +66,9 @@ takes the difficulty out of creating custom brute force jobs
- `crossfire new`: create new crossfire project
- `crossfire test`: test project locally, replicates configuration of server with single local
agent to debug issues
- low priority: `crossfire node-test`: submit a mini-task to a node that has the necessary
resources to debug issues
- `crossfire submit`: submit task to server
- `crossfire cancel`: cancels submitted task
- `crossfire status`: check status of task (or network as a whole)
- low priority: gui interface
- low priority: gui interface (racket/gui & framework time)

View File

@ -40,7 +40,7 @@
;; manifest.rkt processing
(define (parse-manifest manifest-def)
(struct manifest [name arch resources mode command isets pattern] #:transparent)
(struct manifest [name arch resources smp mode command isets pattern] #:transparent)
(define-syntax (check-false stx)
(syntax-case stx ()
@ -51,12 +51,13 @@
(error "manifest attribute missing:" idsym)))]))
(define mf
(for/fold ([mf (manifest #f #f #f 'stdio #f builtin-isets #f)])
(for/fold ([mf (manifest #f '("any") '() #f 'stdio #f builtin-isets #f)])
([line (in-list manifest-def)])
(match line
[(list 'name name) (struct-copy manifest mf [name name])]
[(list 'arch arch ...) (struct-copy manifest mf [arch arch])]
[(list 'resources resources ...) (struct-copy manifest mf [resources resources])]
[(list 'smp smp) (struct-copy manifest mf [smp smp])]
[(list 'mode mode) (struct-copy manifest mf [mode mode])]
[(list 'command command) (struct-copy manifest mf [command command])]
[(list 'iset name val)
@ -87,19 +88,22 @@
[(list start end) (vector (range->integer-set start end))]
[_ (error "unrecognized pattern element in manifest" x)])))
(values (manifest-name mf) (manifest-arch mf) (manifest-resources mf) (manifest-mode mf)
(manifest-command mf) (apply vector-append patterns)))
(values (manifest-name mf) (manifest-arch mf) (manifest-resources mf) (manifest-smp mf)
(manifest-mode mf) (manifest-command mf) (apply vector-append patterns)))
;; test code
(define-values [name arch resources mode command pattern]
(define-values [name arch resources smp mode command pattern]
(parse-manifest
'((name "test")
;; supported arch triples
;; supported arch triples, or "any"
(arch "aarch64-unknown-linux-gnu" "aarch64-linux-gnu")
;; required resources
(resources "hifive-board" "cuda")
;; #t means crossfire will start one instance per CPU
;; #f means only one instance per node
(smp #f)
;; stdio or callback
(mode stdio)
;; command to start the brute force process
@ -110,6 +114,7 @@
(pattern ?m "_?d"))))
(pattern-codegen pattern mode)
;; inclusive range
(define start (resolve-pattern-pos pattern (pos->pattern-pos pattern 10)))
(define end (resolve-pattern-pos pattern (pos->pattern-pos pattern 21)))
(printf "// args: ")