mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-06-10 14:00:21 +02:00
Minor CSE optimization
* module/language/tree-il/cse.scm (cse): Use hashq instead of modulo to convert a full-width hash value to a vector index.
This commit is contained in:
parent
3e1b97c1b0
commit
54c7882a75
1 changed files with 2 additions and 2 deletions
|
@ -1,6 +1,6 @@
|
|||
;;; Common Subexpression Elimination (CSE) on Tree-IL
|
||||
|
||||
;; Copyright (C) 2011, 2012, 2013 Free Software Foundation, Inc.
|
||||
;; Copyright (C) 2011, 2012, 2013, 2014 Free Software Foundation, Inc.
|
||||
|
||||
;;;; This library is free software; you can redistribute it and/or
|
||||
;;;; modify it under the terms of the GNU Lesser General Public
|
||||
|
@ -194,7 +194,7 @@
|
|||
|
||||
|
||||
(define (hasher n)
|
||||
(lambda (x size) (modulo n size)))
|
||||
(lambda (x size) (hashq n size)))
|
||||
|
||||
(define (add-to-db exp effects ctx db)
|
||||
(let ((v (vector exp effects ctx))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue