make/gensrc/GensrcBuffer.gmk
author zgu
Tue, 31 Jul 2018 13:12:06 -0400
changeset 51267 2cd8bbccbd2d
parent 47217 72e3ae9a25eb
child 53110 50677f43ac3d
permissions -rw-r--r--
8199868: Support JNI critical functions in object pinning API Summary: Pin/unpin incoming array arguments of critical native JNI call Reviewed-by: shade, adinn
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
     1
#
27565
729f9700483a 8049367: Modular Run-Time Images
chegar
parents: 25859
diff changeset
     2
# Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
     3
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
     4
#
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
     5
# This code is free software; you can redistribute it and/or modify it
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
     6
# under the terms of the GNU General Public License version 2 only, as
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
     7
# published by the Free Software Foundation.  Oracle designates this
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
     8
# particular file as subject to the "Classpath" exception as provided
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
     9
# by Oracle in the LICENSE file that accompanied this code.
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    10
#
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    11
# This code is distributed in the hope that it will be useful, but WITHOUT
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    12
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    13
# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    14
# version 2 for more details (a copy is included in the LICENSE file that
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    15
# accompanied this code).
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    16
#
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    17
# You should have received a copy of the GNU General Public License version
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    18
# 2 along with this work; if not, write to the Free Software Foundation,
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    19
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    20
#
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    21
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    22
# or visit www.oracle.com if you need additional information or have any
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    23
# questions.
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    24
#
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    25
35241
075bbb8f2423 8146403: Windows build can be faster
erikj
parents: 27565
diff changeset
    26
GENSRC_BUFFER :=
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    27
27565
729f9700483a 8049367: Modular Run-Time Images
chegar
parents: 25859
diff changeset
    28
GENSRC_BUFFER_DST := $(SUPPORT_OUTPUTDIR)/gensrc/java.base/java/nio
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    29
47217
72e3ae9a25eb 8187444: Forest Consolidation: Make build work
erikj
parents: 47216
diff changeset
    30
GENSRC_BUFFER_SRC := $(TOPDIR)/src/java.base/share/classes/java/nio
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    31
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    32
###
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    33
35241
075bbb8f2423 8146403: Windows build can be faster
erikj
parents: 27565
diff changeset
    34
$(GENSRC_BUFFER_DST)/_the.buffer.dir:
075bbb8f2423 8146403: Windows build can be faster
erikj
parents: 27565
diff changeset
    35
	$(call LogInfo, Generating buffer classes)
075bbb8f2423 8146403: Windows build can be faster
erikj
parents: 27565
diff changeset
    36
	$(call MakeDir, $(@D))
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    37
	$(TOUCH) $@
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    38
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    39
define fixRw
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    40
  $1_RW := $2
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    41
  $1_rwkey := rw
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    42
  ifeq (R, $2)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    43
    $1_rwkey := ro
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    44
  endif
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    45
endef
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    46
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    47
define typesAndBits
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    48
  # param 1 target
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    49
  # param 2 type
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    50
  # param 3 BO
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    51
  $1_a := a
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    52
  $1_A := A
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    53
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    54
  $1_type := $2
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    55
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    56
  ifeq ($2, byte)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    57
    $1_x        := b
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    58
    $1_Type     := Byte
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    59
    $1_fulltype := byte
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    60
    $1_Fulltype := Byte
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    61
    $1_category := integralType
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    62
    $1_LBPV     := 0
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    63
  endif
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    64
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    65
  ifeq ($2, char)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    66
    $1_x        := c
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    67
    $1_Type     := Char
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    68
    $1_fulltype := character
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    69
    $1_Fulltype := Character
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    70
    $1_category := integralType
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    71
    $1_streams  := streamableType
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    72
    $1_streamtype := int
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    73
    $1_Streamtype := Int
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    74
    $1_LBPV     := 1
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    75
  endif
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    76
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    77
  ifeq ($2, short)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    78
    $1_x        := s
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    79
    $1_Type     := Short
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    80
    $1_fulltype := short
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    81
    $1_Fulltype := Short
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    82
    $1_category := integralType
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    83
    $1_LBPV     := 1
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    84
  endif
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    85
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    86
  ifeq ($2, int)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    87
    $1_a        := an
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    88
    $1_A        := An
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    89
    $1_x        := i
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    90
    $1_Type     := Int
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    91
    $1_fulltype := integer
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    92
    $1_Fulltype := Integer
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    93
    $1_category := integralType
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    94
    $1_LBPV     := 2
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    95
  endif
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
    96
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    97
  ifeq ($2, long)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    98
    $1_x        := l
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
    99
    $1_Type     := Long
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   100
    $1_fulltype := long
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   101
    $1_Fulltype := Long
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   102
    $1_category := integralType
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   103
    $1_LBPV     := 3
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   104
  endif
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   105
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   106
  ifeq ($2, float)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   107
    $1_x        := f
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   108
    $1_Type     := Float
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   109
    $1_fulltype := float
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   110
    $1_Fulltype := Float
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   111
    $1_category := floatingPointType
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   112
    $1_LBPV     := 2
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   113
  endif
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   114
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   115
  ifeq ($2, double)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   116
    $1_x        := d
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   117
    $1_Type     := Double
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   118
    $1_fulltype := double
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   119
    $1_Fulltype := Double
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   120
    $1_category := floatingPointType
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   121
    $1_LBPV     := 3
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   122
  endif
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   123
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   124
  $1_Swaptype := $$($1_Type)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   125
  $1_memtype := $2
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   126
  $1_Memtype := $$($1_Type)
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   127
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   128
  ifeq ($2, float)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   129
    $1_memtype := int
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   130
    $1_Memtype := Int
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   131
    ifneq ($3, U)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   132
      $1_Swaptype := Int
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   133
      $1_fromBits := Float.intBitsToFloat
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   134
      $1_toBits   := Float.floatToRawIntBits
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   135
    endif
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   136
  endif
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   137
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   138
  ifeq ($2, double)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   139
    $1_memtype := long
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   140
    $1_Memtype := Long
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   141
    ifneq ($3, U)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   142
      $1_Swaptype := Long
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   143
      $1_fromBits := Double.longBitsToDouble
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   144
      $1_toBits   := Double.doubleToRawLongBits
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   145
    endif
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   146
  endif
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   147
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   148
  ifeq ($3, S)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   149
    $1_swap := Bits.swap
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   150
  endif
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   151
endef
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   152
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   153
define genBinOps
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   154
  # param 1 target
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   155
  # param 2 type
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   156
  # param 3 BO
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   157
  # param 4 RW
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   158
  # param 5 nbytes
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   159
  # param 6 nbytesButOne
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   160
  $(call typesAndBits,$1,$2,$3)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   161
  $(call fixRw,$1,$4)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   162
  $1_nbytes := $5
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   163
  $1_nbytesButOne := $6
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   164
  $1_CMD := $(TOOL_SPP) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   165
    -Dtype=$$($1_type) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   166
    -DType=$$($1_Type) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   167
    -Dfulltype=$$($1_fulltype) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   168
    -Dmemtype=$$($1_memtype) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   169
    -DMemtype=$$($1_Memtype) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   170
    -DfromBits=$$($1_fromBits) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   171
    -DtoBits=$$($1_toBits) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   172
    -DLG_BYTES_PER_VALUE=$$($1_LBPV) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   173
    -DBYTES_PER_VALUE="(1 << $$($1_LBPV))" \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   174
    -Dnbytes=$$($1_nbytes) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   175
    -DnbytesButOne=$$($1_nbytesButOne) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   176
    -DRW=$$($1_RW) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   177
    -K$$($1_rwkey) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   178
    -Da=$$($1_a) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   179
    -be
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   180
endef
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   181
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   182
define SetupGenBuffer
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   183
  # param 1 is for output file
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   184
  # param 2 is template dependency
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   185
  # param 3-9 are named args.
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   186
  #   type :=
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   187
  #   BIN :=
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   188
  #   RW := Mutability (R)ead-only (W)ritable
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   189
  #   BO := (U)nswapped/(S)wapped/(L)ittle/(B)ig
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   190
  #
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   191
  $(if $3,$1_$(strip $3))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   192
  $(if $4,$1_$(strip $4))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   193
  $(if $5,$1_$(strip $5))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   194
  $(if $6,$1_$(strip $6))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   195
  $(if $7,$1_$(strip $7))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   196
  $(if $8,$1_$(strip $8))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   197
  $(if $9,$1_$(strip $9))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   198
  $(if $(10),$1_$(strip $(10)))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   199
  $(if $(11),$1_$(strip $(11)))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   200
  $(if $(12),$1_$(strip $(12)))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   201
  $(if $(13),$1_$(strip $(13)))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   202
  $(if $(14),$1_$(strip $(14)))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   203
  $(foreach i,3 4 5 6 7 8 9 10 11 12 13 14 15,$(if $($i),$1_$(strip $($i)))$(NEWLINE))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   204
  $(call LogSetupMacroEntry,SetupGenBuffer($1),$2,$3,$4,$5,$6,$7,$8,$9,$(10),$(11),$(12),$(13),$(14),$(15))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   205
  $(if $(16),$(error Internal makefile error: Too many arguments to SetupGenBuffer, please update GensrcBuffer.gmk))
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   206
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   207
  $(call fixRw,$1,$$($1_RW))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   208
  $(call typesAndBits,$1,$$($1_type),$$($1_BO))
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   209
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   210
  $1_DST := $(GENSRC_BUFFER_DST)/$1.java
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   211
  $1_SRC := $(GENSRC_BUFFER_SRC)/$(strip $2).java.template
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   212
  $1_SRC_BIN := $(GENSRC_BUFFER_SRC)/$(strip $2)-bin.java.template
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   213
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   214
  $1_DEP := $$($1_SRC)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   215
  ifneq ($$($1_BIN), 1)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   216
    $1_DEP := $$($1_SRC)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   217
    $1_OUT := $$($1_DST)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   218
  else
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   219
    $1_DEP += $$($1_SRC) $$($1_SRC_BIN)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   220
    $1_OUT := $(GENSRC_BUFFER_DST)/$1.binop.0.java
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   221
  endif
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   222
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   223
  ifeq ($$($1_BIN), 1)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   224
    $(call genBinOps,$1_char,char,$$($1_BO),$$($1_RW),two,one)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   225
    $(call genBinOps,$1_short,short,$$($1_BO),$$($1_RW),two,one)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   226
    $(call genBinOps,$1_int,int,$$($1_BO),$$($1_RW),four,three)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   227
    $(call genBinOps,$1_long,long,$$($1_BO),$$($1_RW),eight,seven)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   228
    $(call genBinOps,$1_float,float,$$($1_BO),$$($1_RW),four,three)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   229
    $(call genBinOps,$1_double,double,$$($1_BO),$$($1_RW),eight,seven)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   230
  endif
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   231
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   232
  $$($1_DST): $$($1_DEP) $(GENSRC_BUFFER_DST)/_the.buffer.dir
13702
efd6a05935b2 7197849: Update new build-infra makefiles
ohair
parents: 13164
diff changeset
   233
	$(TOOL_SPP) < $$($1_SRC) > $$($1_OUT).tmp \
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   234
	    -K$$($1_type) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   235
	    -K$$($1_category) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   236
	    -K$$($1_streams) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   237
	    -Dtype=$$($1_type) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   238
	    -DType=$$($1_Type) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   239
	    -Dfulltype=$$($1_fulltype) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   240
	    -DFulltype=$$($1_Fulltype) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   241
	    -Dstreamtype=$$($1_streamtype) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   242
	    -DStreamtype=$$($1_Streamtype) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   243
	    -Dx=$$($1_x) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   244
	    -Dmemtype=$$($1_memtype) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   245
	    -DMemtype=$$($1_Memtype) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   246
	    -DSwaptype=$$($1_Swaptype) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   247
	    -DfromBits=$$($1_fromBits) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   248
	    -DtoBits=$$($1_toBits) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   249
	    -DLG_BYTES_PER_VALUE=$$($1_LBPV) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   250
	    -DBYTES_PER_VALUE="(1 << $$($1_LBPV))" \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   251
	    -DBO=$$($1_BO) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   252
	    -Dswap=$$($1_swap) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   253
	    -DRW=$$($1_RW) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   254
	    -K$$($1_rwkey) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   255
	    -Da=$$($1_a) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   256
	    -DA=$$($1_A) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   257
	    -Kbo$$($1_BO)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   258
	$(MV) $$($1_OUT).tmp $$($1_OUT)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   259
        # Do the extra bin thing
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   260
        ifeq ($$($1_BIN), 1)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   261
	  $(SED) -e '/#BIN/,$$$$d' < $$($1_OUT) > $$($1_DST).tmp
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   262
	  $(RM) $$($1_OUT)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   263
	  $$($1_char_CMD) < $$($1_SRC_BIN) >> $$($1_DST).tmp
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   264
	  $$($1_short_CMD) < $$($1_SRC_BIN) >> $$($1_DST).tmp
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   265
	  $$($1_int_CMD) < $$($1_SRC_BIN) >> $$($1_DST).tmp
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   266
	  $$($1_long_CMD) < $$($1_SRC_BIN) >> $$($1_DST).tmp
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   267
	  $$($1_float_CMD) < $$($1_SRC_BIN) >> $$($1_DST).tmp
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   268
	  $$($1_double_CMD) < $$($1_SRC_BIN) >> $$($1_DST).tmp
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   269
	  $(PRINTF) "}\n" >> $$($1_DST).tmp
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   270
	  mv $$($1_DST).tmp $$($1_DST)
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   271
        endif
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   272
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   273
  GENSRC_BUFFER += $$($1_DST)
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   274
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   275
endef
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   276
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   277
###
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   278
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   279
X_BUF := X-Buffer
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   280
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   281
$(eval $(call SetupGenBuffer,ByteBuffer,  $(X_BUF), type:=byte, BIN:=1))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   282
$(eval $(call SetupGenBuffer,CharBuffer,  $(X_BUF), type:=char))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   283
$(eval $(call SetupGenBuffer,ShortBuffer, $(X_BUF), type:=short))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   284
$(eval $(call SetupGenBuffer,IntBuffer,   $(X_BUF), type:=int))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   285
$(eval $(call SetupGenBuffer,LongBuffer,  $(X_BUF), type:=long))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   286
$(eval $(call SetupGenBuffer,FloatBuffer, $(X_BUF), type:=float))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   287
$(eval $(call SetupGenBuffer,DoubleBuffer,$(X_BUF), type:=double))
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   288
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   289
# Buffers whose contents are heap-allocated
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   290
#
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   291
HEAP_X_BUF := Heap-X-Buffer
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   292
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   293
$(eval $(call SetupGenBuffer,HeapByteBuffer,   $(HEAP_X_BUF), type:=byte))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   294
$(eval $(call SetupGenBuffer,HeapByteBufferR,  $(HEAP_X_BUF), type:=byte, RW:=R))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   295
$(eval $(call SetupGenBuffer,HeapCharBuffer,   $(HEAP_X_BUF), type:=char))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   296
$(eval $(call SetupGenBuffer,HeapCharBufferR,  $(HEAP_X_BUF), type:=char, RW:=R))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   297
$(eval $(call SetupGenBuffer,HeapShortBuffer,  $(HEAP_X_BUF), type:=short))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   298
$(eval $(call SetupGenBuffer,HeapShortBufferR, $(HEAP_X_BUF), type:=short, RW:=R))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   299
$(eval $(call SetupGenBuffer,HeapIntBuffer,    $(HEAP_X_BUF), type:=int))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   300
$(eval $(call SetupGenBuffer,HeapIntBufferR,   $(HEAP_X_BUF), type:=int, RW:=R))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   301
$(eval $(call SetupGenBuffer,HeapLongBuffer,   $(HEAP_X_BUF), type:=long))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   302
$(eval $(call SetupGenBuffer,HeapLongBufferR,  $(HEAP_X_BUF), type:=long, RW:=R))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   303
$(eval $(call SetupGenBuffer,HeapFloatBuffer,  $(HEAP_X_BUF), type:=float))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   304
$(eval $(call SetupGenBuffer,HeapFloatBufferR, $(HEAP_X_BUF), type:=float, RW:=R))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   305
$(eval $(call SetupGenBuffer,HeapDoubleBuffer, $(HEAP_X_BUF), type:=double))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   306
$(eval $(call SetupGenBuffer,HeapDoubleBufferR,$(HEAP_X_BUF), type:=double, RW:=R))
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   307
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   308
# Direct byte buffer
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   309
#
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   310
DIRECT_X_BUF := Direct-X-Buffer
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   311
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   312
$(eval $(call SetupGenBuffer,DirectByteBuffer, $(DIRECT_X_BUF), type:=byte, BIN:=1))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   313
$(eval $(call SetupGenBuffer,DirectByteBufferR,$(DIRECT_X_BUF), type:=byte, BIN:=1, RW:=R))
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   314
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   315
# Unswapped views of direct byte buffers
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   316
#
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   317
$(eval $(call SetupGenBuffer,DirectCharBufferU,   $(DIRECT_X_BUF), type:=char, BO:=U))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   318
$(eval $(call SetupGenBuffer,DirectCharBufferRU,  $(DIRECT_X_BUF), type:=char, RW:=R, BO:=U))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   319
$(eval $(call SetupGenBuffer,DirectShortBufferU,  $(DIRECT_X_BUF), type:=short, BO:=U))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   320
$(eval $(call SetupGenBuffer,DirectShortBufferRU, $(DIRECT_X_BUF), type:=short, RW:=R, BO:=U))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   321
$(eval $(call SetupGenBuffer,DirectIntBufferU,    $(DIRECT_X_BUF), type:=int, BO:=U))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   322
$(eval $(call SetupGenBuffer,DirectIntBufferRU,   $(DIRECT_X_BUF), type:=int, RW:=R, BO:=U))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   323
$(eval $(call SetupGenBuffer,DirectLongBufferU,   $(DIRECT_X_BUF), type:=long, BO:=U))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   324
$(eval $(call SetupGenBuffer,DirectLongBufferRU,  $(DIRECT_X_BUF), type:=long, RW:=R, BO:=U))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   325
$(eval $(call SetupGenBuffer,DirectFloatBufferU,  $(DIRECT_X_BUF), type:=float, BO:=U))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   326
$(eval $(call SetupGenBuffer,DirectFloatBufferRU, $(DIRECT_X_BUF), type:=float, RW:=R, BO:=U))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   327
$(eval $(call SetupGenBuffer,DirectDoubleBufferU, $(DIRECT_X_BUF), type:=double, BO:=U))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   328
$(eval $(call SetupGenBuffer,DirectDoubleBufferRU,$(DIRECT_X_BUF), type:=double, RW:=R, BO:=U))
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   329
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   330
# Swapped views of direct byte buffers
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   331
#
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   332
$(eval $(call SetupGenBuffer,DirectCharBufferS,   $(DIRECT_X_BUF), type:=char, BO:=S))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   333
$(eval $(call SetupGenBuffer,DirectCharBufferRS,  $(DIRECT_X_BUF), type:=char, RW:=R, BO:=S))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   334
$(eval $(call SetupGenBuffer,DirectShortBufferS,  $(DIRECT_X_BUF), type:=short, BO:=S))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   335
$(eval $(call SetupGenBuffer,DirectShortBufferRS, $(DIRECT_X_BUF), type:=short, RW:=R, BO:=S))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   336
$(eval $(call SetupGenBuffer,DirectIntBufferS,    $(DIRECT_X_BUF), type:=int, BO:=S))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   337
$(eval $(call SetupGenBuffer,DirectIntBufferRS,   $(DIRECT_X_BUF), type:=int, RW:=R, BO:=S))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   338
$(eval $(call SetupGenBuffer,DirectLongBufferS,   $(DIRECT_X_BUF), type:=long, BO:=S))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   339
$(eval $(call SetupGenBuffer,DirectLongBufferRS,  $(DIRECT_X_BUF), type:=long, RW:=R, BO:=S))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   340
$(eval $(call SetupGenBuffer,DirectFloatBufferS,  $(DIRECT_X_BUF), type:=float, BO:=S))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   341
$(eval $(call SetupGenBuffer,DirectFloatBufferRS, $(DIRECT_X_BUF), type:=float, RW:=R, BO:=S))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   342
$(eval $(call SetupGenBuffer,DirectDoubleBufferS, $(DIRECT_X_BUF), type:=double, BO:=S))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   343
$(eval $(call SetupGenBuffer,DirectDoubleBufferRS,$(DIRECT_X_BUF), type:=double, RW:=R, BO:=S))
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   344
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   345
# Big-endian views of byte buffers
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   346
#
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   347
BYTE_X_BUF := ByteBufferAs-X-Buffer
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   348
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   349
$(eval $(call SetupGenBuffer,ByteBufferAsCharBufferB,   $(BYTE_X_BUF), type:=char, BO:=B))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   350
$(eval $(call SetupGenBuffer,ByteBufferAsCharBufferRB,  $(BYTE_X_BUF), type:=char, RW:=R, BO:=B))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   351
$(eval $(call SetupGenBuffer,ByteBufferAsShortBufferB,  $(BYTE_X_BUF), type:=short, BO:=B))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   352
$(eval $(call SetupGenBuffer,ByteBufferAsShortBufferRB, $(BYTE_X_BUF), type:=short, RW:=R, BO:=B))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   353
$(eval $(call SetupGenBuffer,ByteBufferAsIntBufferB,    $(BYTE_X_BUF), type:=int, BO:=B))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   354
$(eval $(call SetupGenBuffer,ByteBufferAsIntBufferRB,   $(BYTE_X_BUF), type:=int, RW:=R, BO:=B))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   355
$(eval $(call SetupGenBuffer,ByteBufferAsLongBufferB,   $(BYTE_X_BUF), type:=long, BO:=B))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   356
$(eval $(call SetupGenBuffer,ByteBufferAsLongBufferRB,  $(BYTE_X_BUF), type:=long, RW:=R, BO:=B))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   357
$(eval $(call SetupGenBuffer,ByteBufferAsFloatBufferB,  $(BYTE_X_BUF), type:=float, BO:=B))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   358
$(eval $(call SetupGenBuffer,ByteBufferAsFloatBufferRB, $(BYTE_X_BUF), type:=float, RW:=R, BO:=B))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   359
$(eval $(call SetupGenBuffer,ByteBufferAsDoubleBufferB, $(BYTE_X_BUF), type:=double, BO:=B))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   360
$(eval $(call SetupGenBuffer,ByteBufferAsDoubleBufferRB,$(BYTE_X_BUF), type:=double, RW:=R, BO:=B))
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   361
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   362
# Little-endian views of byte buffers
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   363
#
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   364
$(eval $(call SetupGenBuffer,ByteBufferAsCharBufferL,   $(BYTE_X_BUF), type:=char, BO:=L))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   365
$(eval $(call SetupGenBuffer,ByteBufferAsCharBufferRL,  $(BYTE_X_BUF), type:=char, RW:=R, BO:=L))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   366
$(eval $(call SetupGenBuffer,ByteBufferAsShortBufferL,  $(BYTE_X_BUF), type:=short, BO:=L))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   367
$(eval $(call SetupGenBuffer,ByteBufferAsShortBufferRL, $(BYTE_X_BUF), type:=short, RW:=R, BO:=L))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   368
$(eval $(call SetupGenBuffer,ByteBufferAsIntBufferL,    $(BYTE_X_BUF), type:=int, BO:=L))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   369
$(eval $(call SetupGenBuffer,ByteBufferAsIntBufferRL,   $(BYTE_X_BUF), type:=int, RW:=R, BO:=L))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   370
$(eval $(call SetupGenBuffer,ByteBufferAsLongBufferL,   $(BYTE_X_BUF), type:=long, BO:=L))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   371
$(eval $(call SetupGenBuffer,ByteBufferAsLongBufferRL,  $(BYTE_X_BUF), type:=long, RW:=R, BO:=L))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   372
$(eval $(call SetupGenBuffer,ByteBufferAsFloatBufferL,  $(BYTE_X_BUF), type:=float, BO:=L))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   373
$(eval $(call SetupGenBuffer,ByteBufferAsFloatBufferRL, $(BYTE_X_BUF), type:=float, RW:=R, BO:=L))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   374
$(eval $(call SetupGenBuffer,ByteBufferAsDoubleBufferL, $(BYTE_X_BUF), type:=double, BO:=L))
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 17922
diff changeset
   375
$(eval $(call SetupGenBuffer,ByteBufferAsDoubleBufferRL,$(BYTE_X_BUF), type:=double, RW:=R, BO:=L))
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   376
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   377
###
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents:
diff changeset
   378
25859
3317bb8137f4 8054834: Modular Source Code
chegar
parents: 23010
diff changeset
   379
$(GENSRC_BUFFER): $(BUILD_TOOLS_JDK)
3317bb8137f4 8054834: Modular Source Code
chegar
parents: 23010
diff changeset
   380
GENSRC_JAVA_BASE += $(GENSRC_BUFFER)