Tíquete #30258

Buffer overrun in BFGS::UpdateHessian

: 2012-12-04 22:26 Última Atualização: 2012-12-05 00:04

Relator:
Dono:
(Nenhum)
Tipo:
Estado:
Aberto
Componente:
(Nenhum)
Marcos:
(Nenhum)
Prioridade:
6
Gravidade:
6
Resolução:
Nenhum
Arquivo:
Nenhum

Details

Buffer overrun error occurs if the dimension of the Hessian is odd number.

This bug is found on the binary built with OpenBLAS.

Ticket History (2/2 Histories)

2012-12-04 22:26 Updated by: ktns
  • New Ticket "Buffer overrun in BFGS::UpdateHessian" created
2012-12-05 00:04 Updated by: ktns
Comentário

The code below reproduces this error.

This bug should be related to the byte alignment problem.

#include <cblas.h>
#include <stdlib.h>


int main(void){
	double *x = malloc(sizeof(double)*5);
	double *A = malloc(sizeof(double)*25);
	for(int i = 0; i<5 ; i++){
		x[i]=i;
	}

	for(int i = 0; i<25; i++){
		A[i]=0;
	}

	cblas_dsyr(CblasRowMajor, CblasUpper,
			5, 1, x, 1, A, 5);

	free(x);
	free(A);
	return 0;
}

Attachment File List

No attachments

Editar

Please login to add comment to this ticket » Login